feathersui-starling
feathersui-starling copied to clipboard
Text renderers: Truncate with a maximum line count
Would be nice to have some property like "maxLines" on TextFieldTextRenderer. Currently I have to subclass it to access the TextField instance and use the numLines property and the getLineOffset method to truncate the text.
UP vote! :+1:
I like the idea of max line count better than maxHeight, but maybe both could be supported.
Guys, GREAT NEWS!
I've just found the official TruncationOptions Class in the API.
Implementing this for the TLF will ensure that the text has a limit of text lines AND that the truncation indicator passed is used and the end of that line.
here is the link again: http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flashx/textLayout/factory/TruncationOptions.html