2016-10-13 00:16:48 点击量:10 标签: 收藏本文
设置htmlText属性值为HTML内容
- package {
- import flash.display.Sprite;
- import flash.text.TextField;
- import flash.text.TextFieldType;
- public class Sample0323 extends Sprite
- {
- public function Sample0323()
- {
- var text:TextField = new TextField();
- text.type = TextFieldType.INPUT;
- text.border = true;
- text.borderColor = 0xFFFF00;
- text.height = 20;
- text.htmlText = "<a href='http://www.baidu.com/' target='_blank'><i><u>跳转到百度CuPlayer.com</u></i></a>";
- text.appendText("CuPlayer.com增加的内容");
- this.addChild(text);
- }
- }
- }