Hello, world!

by aasdb
♥0 | Line 20 | Modified 2010-07-06 23:28:43 | MIT License
play

ActionScript3 source code

/**
 * Copyright aasdb ( http://wonderfl.net/user/aasdb )
 * MIT License ( http://www.opensource.org/licenses/mit-license.php )
 * Downloaded from: http://wonderfl.net/c/4yw9
 */

package {
    import flash.text.TextFormat;
    import flash.text.TextField;
    import flash.display.Sprite;
    public class FlashTest extends Sprite {
        public function FlashTest() {
            var t:TextField = new TextField;
            var tf:TextFormat = new TextFormat;
            t.text = "Hello, world.\nHello, wonderfl!";
            t.x = 60;
            t.y = 150;
            t.width = 400;
            t.height = 300;
            tf.size = 50;
            tf.italic = true;
            t.setTextFormat(tf);
            addChild(t);
        }
    }
}