import flash.text.Font;
import flash.display.Sprite;
import flash.text.TextField;
import flash.text.TextFieldType;
import flash.text.TextFormat;
import flash.text.TextFormatAlign;
@:font("assets/fonts/Verdana.ttf") class VerdanaNormal extends Font { }
class FontsFL {
public static var VERDANA;
}
class TitleCardFL extends TitleCardBase
{
var title:TextField;
public function new()
{
super();
Font.registerFont(VerdanaNormal);
FontsFL.VERDANA = new VerdanaNormal().fontName;
this.title = new TextField();
this.addChild(this.title);
this.title.selectable = false;
this.title.x = this.title.y = 6;
this.title.width = 120;
this.title.text = "OpenLR";
this.title.defaultTextFormat = new TextFormat(FontsFL.VERDANA, 24, 0xCC00CC);
}
}
The above is more or less how I’m trying to execute it. I get no errors, my code compiled successfully, but the text field does not reflect the changes I have outlined when calling this.title.defaultTextFormat = new TextFormat(FontsFL.VERDANA, 24, 0xCC00CC);