使用textField.htmlText
多种字体颜色的最佳方法是什么?
我已经使用过代码:
textField.htmlText = "blaa blaa" + "< u >"+w+"< /u >"+"blaa blaa"
如何定义特定颜色?
答案 0 :(得分:3)
var style:StyleSheet = new StyleSheet();
var underline:Object = new Object();
underline.fontWeight = "bold";
underline.color = "#FF0000";
underline.display = "inline";
style.setStyle("u", underline);
textField.styleSheet = style;
textField.htmlText = "blaa blaa" + "< u >"+w+"< /u >"+"blaa blaa"
答案 1 :(得分:0)
FONT标签更容易