Return to Snippet

Revision: 14054
at May 18, 2009 06:05 by pfeisinger


Initial Code
var embeddedFontsArray: Array = Font.enumerateFonts(false);
for (var i:uint = 0; i < embeddedFontsArray.length; i++)
{
	trace("fontName: " + embeddedFontsArray[i].fontName);
}

var t:TextField = new TextField();
addChild(t);

var tf:TextFormat = new TextFormat();
tf.font = "Verdana";
tf.size = 14;

t.embedFonts = true;
t.defaultTextFormat = tf;
t.antiAliasType = AntiAliasType.ADVANCED;
t.text = "Verdana";
t.autoSize = TextFieldAutoSize.LEFT;

stop();

Initial URL

                                

Initial Description

                                

Initial Title
Embed Font From Library

Initial Tags
actionscript, text

Initial Language
ActionScript 3