Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何在spark:TextInput中用两种或多种颜色为单词着色?
我使用带有htmlText属性的mx:TextInput做到了,但我在spark组件中找不到它。
谢谢
<s:TextArea id="txt_ar" textAlign="justify" borderAlpha="0" editable="false">
然后写你的html字符串
textrichtml:String = "your html string"
然后使用以下代码。
txt_ar.textFlow = TextConverter.importToFlow(textrichtml,TextConverter.TEXT_FIELD_HTML_FORMAT);