Layout Variants

QLogic

Member
Licensed User
Longtime User
I have a question on the Varients.

As new phones keep coming out, what sizes and scalability should I be focusing on to make sure that there is limited "fragmentation"? I know that the Galaxy Nexus uses 720x1184 with a 2.0 scale, or the Razr uses 540x960 with a 1.5 scale.

Thanks.
 
Last edited:

Erel

B4X founder
Staff member
Licensed User
Longtime User
I recommend you to start with the three default variants (phone, 7'' and 10'').
The default phone variant is: 360x480, scale=1.0. This is equivalent to: 540x720, scale=1.5 or 720x960, scale=2.0.
This means that the two mentioned devices are slightly longer.

You can do the small adjustments later with code. In the next version it will be simpler with the new designer scripts feature.
 
Upvote 0

Mahares

Expert
Licensed User
Longtime User
Erel:
You responded with the following: The default phone variant is: 360x480, scale=1.0
But, why is the default phone variant on the designer is showing: 320x480, scale 1.
Please elaborate. For instance, if I am developing using a device with 540x960 scale 1.5, what layout do I need to select so I know the application will fit on MOST smaller and larger devices.
Thank you.
 
Upvote 0

Mahares

Expert
Licensed User
Longtime User
Yes, I read the article before and read it again per your recommendation. However, the more you read it the more it becomes not a clear cut choice. I am using a layout of 320x480, density1, 160 dpi on the abstract designer for this particular application. The views are done on the designer, not programmatically. I am not using the emulator. I am porting this app to a device that has the following: 540x960, density=1.5, 240 dpi. When displayed on the device, there is a lot of empty space. How do I get it to use the full screen on that device and yet have it adjust to a smaller device 320x480 and occupy the full screen in both instances. I have read some of Erel's responses in diverse posts where he recommends to always start with 320x480 which I am doing. I am having a hard time coming to grips with the real solution.
Thank you
 
Upvote 0
Top