2

I would like to learn from experienced developers Android, as you develop a UI for different screens? For example, now I have this problem:

I have an element (TextView), which should be placed as nearly aligned to the left, but not back to back, but with a slight indentation. Accordingly, the bigger the screen, so this should become more padding. If it is set fixed (px / dp), as layout_marginLeft, it will remain so for all screens.

Or, like I have a button, which should take approximately the width of the percent of 60, while the remaining 40 percent are left blank. How can this be done without specifying a fixed size?

Is it possible to design a universal screen, which will stretch to compress the distance between the elements (as in my case), and do other similar things? Or is it necessary for each screen to create a resource directory and a separate design for each screen? How do you usually do that?

Thank you in advance for your reply, it is very important to me.

William Lewis
  • 536
  • 1
  • 8
  • 26
user1023177
  • 641
  • 3
  • 10
  • 18
  • 1
    This is a very general question. Google provides some guidelines and recommendations on best practices (linked to in Reno's answer), but you shouldn't expect us to divine the specifics of your problems, and then solve them for you. Read the guidelines and best practices, try to implement your UI, and if you run into difficulties, ask those questions – Chris Bye Nov 10 '11 at 05:25

1 Answers1

4

Some tips :

Community
  • 1
  • 1
Reno
  • 33,594
  • 11
  • 89
  • 102