import flash.display.Sprite; import flash.text.TextField; public class Main extends Sprite { public function Main( ) { var field:TextField = new TextField( ); var formatter:flash.text.TextFormat = new flash.text.TextFormat( ); formatter.color = 0x0000FF; // Make the text blue field.htmlText = "<font face='Arial'>Formatted text</font>"; formatter.font = "Arial"; formatter.font = "Arial, Verdana, Helvetica"; addChild(field); } } }
Related Scripts with Example Source Code in same category :