Android Question Different label text size between variants in Designer

Arf

Well-Known Member
Licensed User
Longtime User
I see in the designer the test size for a label is not alterable between variants. I think I read somewhere that if using the designer, it's not a good idea to hard code text sizes etc in code. Am I right so far?
I wanted to have a different background bitmap and text size for the same label in different orientations, do I need to either abandon this idea or abandon the Designer? I don't want to do the latter.
 

klaus

Expert
Licensed User
Longtime User
I see in the designer the test size for a label is not alterable between variants.
What do you mean with this ?
If you have different layout variants you can change the text size in each variant.
You need to give more information, or better post your project with a precise explanation what you expect and you find beeing wrong.
 
Upvote 0

Arf

Well-Known Member
Licensed User
Longtime User
Hi Klaus, well, I have 3 variants. I select label1 on variant 1 and set Text Style->Size to 28 and save it, then I change to variant 2, select label1 and change the Text Style->Size to 20 and save it.
Now if I go back to variant1, I see the Text Style->Size is now set to 20.

So it seems in whichever variant I am in, changing text size changes the text size for all my variants.
 
Upvote 0

Mahares

Expert
Licensed User
Longtime User
You can change the textsize in the designer variant specific script for each variant, say:
For variant 1: et.TextSize=28 and for variant 2 you can enter: et.TextSize=20
 
Upvote 0

Arf

Well-Known Member
Licensed User
Longtime User
I can't seem to do that, each change in one changes all the others! What am I doing wrong?
Screen Capture here:

 
Upvote 0

Mahares

Expert
Licensed User
Longtime User
Not in the Designer,. You need to change it in the Designer script window: See below:
upload_2014-2-27_18-4-36.png


upload_2014-2-27_18-5-22.png
 
  • Like
Reactions: Arf
Upvote 0
Top