TextField HtmlText Sample on 2011-8-23
TextField HtmlText Sample
♥0 |
Line 20 |
Modified 2011-08-23 16:35:32 |
MIT License
archived:2017-03-20 07:30:39
ActionScript3 source code
/**
* Copyright momolab ( http://wonderfl.net/user/momolab )
* MIT License ( http://www.opensource.org/licenses/mit-license.php )
* Downloaded from: http://wonderfl.net/c/hqz1
*/
package
{
import flash.display.Sprite;
import flash.text.TextField;
import flash.text.TextFieldAutoSize;
import flash.text.TextFieldType;
public class TextFieldHtmlTextSample extends Sprite
{
public function TextFieldHtmlTextSample()
{
var tf:TextField = new TextField();
tf.autoSize = TextFieldAutoSize.LEFT;
tf.type = TextFieldType.INPUT;
tf.multiline = true;
addChild(tf);
var htmlText:String = '<p><h1><b>TextField HtmlText Sample</b></h1><br /><img src="http://cdn1.iconfinder.com/data/icons/walle/64/my_computer.png" >as<b>d</b>fa<font size="20">sd</font>fasdfasdf<br />asdfasdfasdfasdfsa<br />hihihihihi</p>';
tf.htmlText = htmlText;
}
}
}