package{
import flash.display.Sprite;
import flash.text.*;
public class Main extends Sprite{
public function Main(){
var t:TextField = new TextField( );
t.text = "hello world";
var fontFormat:TextFormat = new TextFormat( );
fontFormat.font = "Courier New";
var boldFormat:TextFormat = new TextFormat( );
boldFormat.bold = true;
t.setTextFormat(fontFormat, 0, 11);
t.setTextFormat(boldFormat, 6, 11);
addChild(t);
}
}
}
|