[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Setting Mobile StageText height to fit multiline content

The native StyleableStageText and StageText controls (and the skins that use them) do not appear to support auto-sizing height to multiline content like a multiline Label (non-native) control does. 

Can StageText be configured to auto-size vertically to display all content exactly? 

There appears to be no way to measure the text extents of native controls, so I cannot write my own logic to size the height. Based on a fixed width and font size and family, I need a way to know the width of a line of text to calculate the line breaks, but another rub is this has to be done with Emoji characters too.

The reason I need this at all is because I need to display Emoji characters the user may enter from the soft keyboard. This is a social network-like app and Emoji support is required and posted messages cannot be of fixed height or lines will be truncated, or there will be many blank lines below the content.

It seems there must be a native property that will cause the native control used by StageText to auto-size vertically to content and nobody thought to expose that property in Flex. I wonder if this is accurate enough to open an issue against Flash/AIR and possibly Flex to extend StageText to do this.

Thanks for your suggestions!