Return to Snippet

Revision: 31481
at September 10, 2010 19:07 by coprolit


Updated Code
[Embed(source='C:/WINDOWS/Fonts/verdana.ttf', fontFamily="Verdana", fontWeight="regular", embedAsCFF="false")]
public var Verdana:Class;

private var mytextfield:TextField = new TextField();
private var mytextformat:TextFormat = new TextFormat();

/*
... class declaration ...
*/

mytextformat.font = "Verdana";

mytextfield.embedFonts = true;
mytextfield.defaultTextFormat = mytextformat;

Revision: 31480
at September 7, 2010 17:26 by coprolit


Initial Code
[Embed(source='C:/WINDOWS/Fonts/verdana.ttf', fontFamily="Verdana", embedAsCFF="false")]
public var Verdana:Class;

private var mytextfield:TextField = new TextField();
private var mytextformat:TextFormat = new TextFormat();

/*
... class declaration ...
*/

mytextformat.font = "Verdana";

mytextfield.embedFonts = true;
mytextfield.defaultTextFormat = mytextformat;

Initial URL

                                

Initial Description

                                

Initial Title
Embed truetype font in FlashDevelop (Flex 4+)

Initial Tags
flash, Flex

Initial Language
ActionScript 3