Android Question display resolution

Toni

Member
Licensed User
Longtime User
Hello,
I own a Samsung S24+. The resolution should be as Samsung says 1440 x 3120 pixel. In the designer statusbar it shows only a resolution of 1080 x 2121! pixel with a scale of 2.8125 by 450dpi. If i try to use this bandy resolution then I'am advised to use 384 x 754 pixel to fit 160dpi. If i try to configure my real smartphone resolution I've got not such advice. Even I use always dip values e.g. for left and top of a view it do not fit the layout values. Even if I tried out the 'First programm' lesson the views never in the middle. I have to put always an offset of 12 to all Views left property according to the activity. It makes no difference if I use Wlan or USB B4A bridge. Anybody with any ideas? Thanks in advance!
 

Brian Dean

Well-Known Member
Licensed User
Longtime User
If you are using the Visual Designer then you should not even be thinking about the real resolution of your device. In fact in any layout design you should not be thinking of the actual device resolution because devices differ.

There are several videos that explain how to use the B4X Visual Designer. Look particularly at the one here that explains how to use anchors. This shows how you can "tie" views to the dimensions of your device screen - the main problem that you seem to be grappling with.

Edit : Corrected YouTube link.
 
Last edited:
Upvote 0
Top