Andre Souza Member Licensed User Jan 9, 2016 #1 Hello. How do I know the size of the text height in designer script Try label1.height = -2 He worked , but with the label1.heigth command can not know the size set he got . I need to know that size, so that my right sequence. B4X: 'All variants script AutoScaleAll Button1.HorizontalCenter = 50%x Button2.HorizontalCenter = 50%x Label1.HorizontalCenter = 50%x Label1.Height = -2 Button1.Top = Label1.Height + 20dip Label1.Top = Button1.Height+Button1.Top + 20dip Button2.Top = Label1.Height + Label1.Top + 20dip Attachments imagem_1.png 73.8 KB · Views: 217 imagem_2.png 133.8 KB · Views: 224
Hello. How do I know the size of the text height in designer script Try label1.height = -2 He worked , but with the label1.heigth command can not know the size set he got . I need to know that size, so that my right sequence. B4X: 'All variants script AutoScaleAll Button1.HorizontalCenter = 50%x Button2.HorizontalCenter = 50%x Label1.HorizontalCenter = 50%x Label1.Height = -2 Button1.Top = Label1.Height + 20dip Label1.Top = Button1.Height+Button1.Top + 20dip Button2.Top = Label1.Height + Label1.Top + 20dip
Erel B4X founder Staff member Licensed User Longtime User Jan 10, 2016 #2 I recommend you to use CustomListView for such layout. You can add the text with AddText and then add the button with a regular item. Internally CustomListView uses StringUtils.MeasureTextHeight to compute the height. Upvote 0
I recommend you to use CustomListView for such layout. You can add the text with AddText and then add the button with a regular item. Internally CustomListView uses StringUtils.MeasureTextHeight to compute the height.
Andre Souza Member Licensed User Jan 11, 2016 #3 Thank You. I will do manually with the class StringUtils.MeasureTextHeight. The class CustomListView through complicated so I can understand for now Upvote 0
Thank You. I will do manually with the class StringUtils.MeasureTextHeight. The class CustomListView through complicated so I can understand for now