Android Question Label Text Alignment

kentco

Member
Licensed User
Longtime User
Hi All

I have a label and i am adding text to it. The text is words all with the same number of characters but depending on the characters in the word the length can be different. I thought of adding a tab (same as pressing tab key on the keyboard) so the text would always start vertically aligned I have tried CHR(9) but this does not work. Are tab supported in labels if so how do you add them? Or is there a better way to align the text?

for example
RUNNING RUNNER
ABDOMEN RUNNER

RUNNING (TAB) RUNNER
ABDOMEN (TAB)RUNNER

Thanks
Colin
 
Last edited:

stevel05

Expert
Licensed User
Longtime User
The easy answer if you only ever have two words would be to use two labels. Alternatively you could use the MONOSPACE Typeface and pad the gaps to the correct length with spaces.
 
Upvote 0

Theera

Well-Known Member
Licensed User
Longtime User
Hi kentco,
You can use Margret's stringfunction library.
 
Upvote 0
Top