var myButton = new Button;
var libraryFont:Font = new myFont;
var myFormat:TextFormat = new TextFormat();
myFormat.font = libraryFont.fontName;
myFormat.size = 26;
myButton.setStyle("embedFonts", true);
myButton.setStyle("textFormat", myFormat);
this.addChild(myButton)
Assuming the myFont represents an exported for actionscript font from the library in the fla file, the following will work.
Problem is, normally when you change a button’s enabled property, in the disabled state it gets more transparent plus the font gets grey instead of black.
However with my embedded font the label just disappears instead of going gray.
Is this a common problem or am I missing something ?
Cheers