In my app users can input text that is displayed in labels. If they enter "too much", the label will expand by adding a second or third line. I want to prevent that.
I want the label to stay unchanged even if the text is too long. Either of two options are acceptible to me:
Text simply cuts off at the end if the end of the label is reached
The original label component does not have these properties, unless you experimentally set its height to the appropriate number of pixels. You can use the LabelPlus extension to specify the height, e.g. in number of rows.
You can do it this way by specifying a fixed height in pixels. But phones have subtitle size settings, so the same text may have different sizes in different phones.
I have already marked this as solved, because the extension works for me in that it prevents the label from expanding.
As for the two options I mention in my initial post, this does it the first way, by cutting off the text (it does this at a space between words, if available, and otherwise just within a word).
As for the scrolling, it does not work for me, even when I put the lable in a horizontal scroll arrangement. It does scroll, but not like the textbox. It scrolls vertically. Text_input_label.aia (54.5 KB)
I actually discivered the text shortening block just after posting my last message here and found it perfect for my case. Three dots added at the end are quite clear for the user. As this info in my app is inputted by the user themselves, it is a hint to them to keep their text shorter.