This was what i was using
[Embed(source = "../../../assets/fonts/MyriadPro-Regular.otf", fontName = "_MyriadPro", mimeType = "application/x-font")]
public static var FONT_MYRIAD_PRO:Class;
[Embed(source = "../../../assets/fonts/MyriadPro-Bold.otf", fontName = "_MyriadPro", mimeType = "application/x-font")]
public static var FONT_MYRIAD_PRO_B:Class;
The correct method is add the weight and/ or style property.
[Embed(source = "../../../assets/fonts/MyriadPro-Regular.otf", fontName = "_MyriadPro",fontWeight="normal", mimeType = "application/x-font")]
public static var FONT_MYRIAD_PRO:Class;
[Embed(source = "../../../assets/fonts/MyriadPro-Bold.otf", fontName = "_MyriadPro", fontWeight="bold", mimeType = "application/x-font")]
public static var FONT_MYRIAD_PRO_B:Class;
Same way if you want to embed italics version of the font, you will have to add "fontStyle='italics'" to the code.
Bhoot! how you been?
ReplyDeletedoing good.. though quite bored... missing KA though.. trying to play the normal worlds but it just aint much fun... :-(
ReplyDelete