Hi i have some problems with sizes in different devices:
Here is the script from designer i wrote:
And theese are the results in my different devices:
Hay can i put the label text size to be the same size in all of them i mean, above the sandwich icon in tablets the label is like 1/3 wide of the image of the sandwich but in the mobile phone its like 2/3 wide. and the text looks smaller in tablets in comparison to the screen than in the phone...
How can i fix it??
Any idea??
thanks!!
Tablet 10.1"
Tablet 7"
Samsung Galaxy Express II
Here is the script from designer i wrote:
B4X:
'All variants script
AutoScaleAll
iconsize=25%x
logosize= 30%x
margenV=5%y
IconMargin= IconSize*0.25
'Tamaños
ImLogo.Width=logosize
ImLogo.Height=logosize
imVer.Height=60%x
imVer.Width=2dip
ImHor.Width=60%x
ImHor.Height=2dip
'
BtnOfertas.Width= iconsize
BtnOfertas.height= iconsize
BtnPinchos.Width= iconsize
BtnPinchos.height= iconsize
BtnLocation.Width= iconsize
BtnLocation.height= iconsize
BtnCodigos.Width= iconsize
BtnCodigos.height= iconsize
'Posiciones
ImLogo.HorizontalCenter=50%x
ImLogo.Top = 7%y
imVer.Top= ImLogo.top + ImLogo.Height + MargenV
imVer.HorizontalCenter=50%x
ImHor.Left= 20%x
ImHor.Top= imVer.Top+imVer.Height * 0.5
'Botones
BtnOfertas.Width=IconSize
BtnOfertas.Height= IconSize
BtnOfertas.Top= ImHor.Top -IconSize -IconMargin
BtnOfertas.Left= imVer.left - IconSize-IconMargin
BtnPinchos.Width=IconSize
BtnPinchos.Height= IconSize
BtnPinchos.Top= ImHor.Top -IconSize -IconMargin
BtnPinchos.Left= imVer.left +IconMargin
BtnCodigos.Width=IconSize
BtnCodigos.Height= IconSize
BtnCodigos.Top= ImHor.Top+IconMargin
BtnCodigos.Left= imVer.Left-IconMargin-IconSize
BtnLocation.Width=IconSize
BtnLocation.Height= IconSize
BtnLocation.Top= ImHor.Top+IconMargin
BtnLocation.Left= imVer.Left+IconMargin
'Etiquetas
lblOfertas.Text="Ofertas"
lblOfertas.TextSize=16
lblOfertas.Left= BtnOfertas.Left
lblOfertas.Width= BtnOfertas.width
lblOfertas.Height=24dip
lblOfertas.Top= BtnOfertas.Bottom - 0.2*lblOfertas.height
lblPinchos.Text="Pinchos"
lblPinchos.TextSize=16
lblPinchos.Left= BtnPinchos.Left
lblPinchos.Width= BtnPinchos.width
lblPinchos.Height=24dip
lblPinchos.Top= lblOfertas.top
lblCodigos.Text="Códigos"
lblCodigos.TextSize=16
lblCodigos.Left= BtnCodigos.Left
lblCodigos.Top= BtnCodigos.Bottom
lblCodigos.Width= BtnCodigos.Width
lblCodigos.Height= 24dip
lblLocation.Text="Cómo llegar"
lblLocation.TextSize=16
lblLocation.Left= BtnLocation.Left
lblLocation.Top= BtnCodigos.Bottom
lblLocation.Width= BtnLocation.width
lblLocation.Height= 24dip
'Iconos Share
ImTwitter.Width= 0.45*IconSize
ImTwitter.Top= lblCodigos.Top+lblCodigos.Height + MargenV * 2
ImTwitter.height =0.45*IconSize
ImTwitter.Left = imVer.Left - ImTwitter.Width - 0.20 * ImTwitter.width
ImFacebook.Width= 0.45*IconSize
ImFacebook.Top= lblCodigos.Top+lblCodigos.Height + MargenV * 2
ImFacebook.height =0.45*IconSize
ImFacebook.Left = ImTwitter.Left - ImFacebook.Width - 0.4* ImFacebook.width
imShare.Width= 0.45*IconSize
imShare.Top=lblCodigos.Top+lblCodigos.Height + MargenV * 2
imShare.height= 0.45*IconSize
imShare.Left=imVer.Left + 0.20 * ImTwitter.width
ImWifi.Width= 0.45*IconSize
ImWifi.Top=lblCodigos.Top+lblCodigos.Height + MargenV * 2
ImWifi.height= 0.45*IconSize
ImWifi.Left=imShare.Left + ImWifi.Width+ 0.40 * ImWifi.width
And theese are the results in my different devices:
Hay can i put the label text size to be the same size in all of them i mean, above the sandwich icon in tablets the label is like 1/3 wide of the image of the sandwich but in the mobile phone its like 2/3 wide. and the text looks smaller in tablets in comparison to the screen than in the phone...
How can i fix it??
Any idea??
thanks!!
Tablet 10.1"
Tablet 7"
Samsung Galaxy Express II