Android Question Tablet 7 vs Smart 5, same code, diferent sizes

Alberto Michelis

Well-Known Member
Licensed User
Longtime User
Hi,
Im trying to get a better view in a tablet 7.
Same code, nothing changes betwwen a Samsung Note 3 5" vs an LG tablet 7" and the app in the tablet looks smaller, see image...
Titles and data in the tablet is smaller than the phone... same code
Why is this happening any idea to get it better?
Thanks
 

Attachments

  • tamanios.png
    tamanios.png
    180.4 KB · Views: 170

Cableguy

Expert
Licensed User
Longtime User
It's happening because the devices have different screen sizes and densities. If you are not scaling using dip or %, then it will look smaller
 
Upvote 0

Alberto Michelis

Well-Known Member
Licensed User
Longtime User
Then I´ll have to add a Tablet variant and use AutoScaleRate(xx) ?
Is there any way to use app varibles in the view script variant code?
Thanks
 
Upvote 0

Cableguy

Expert
Licensed User
Longtime User
use percentage when positioning like label1.Left = 10%x
imagine your screen in a grid, make it as small as you are confortable with and place your views. use anchors, try to relativize to the max the views positions, like the next view left is taken from the previous view right.
 
Upvote 0

Cableguy

Expert
Licensed User
Longtime User
without seeing the layout its hard to tell. I have a 7" with me if you want me to try
 
Upvote 0

Alberto Michelis

Well-Known Member
Licensed User
Longtime User
Thank you very much, ive attached the .bal, you may see the difference just looking at the labels an how small they seams in the tablet.
 

Attachments

  • precios.bal
    5.9 KB · Views: 117
Upvote 0

Alberto Michelis

Well-Known Member
Licensed User
Longtime User
I am using AutoScale, not using anchors, no need, the screen is very very simple, it looks ok but the font size and the list line height are smaller than a phone.
I´ve posted my .bal, its easy to see.
 
Upvote 0
Top