Quantcast
Channel: Adobe Community : All Content - AIR Development
Viewing all articles
Browse latest Browse all 2954

Embedding Font in FB 4.7 AIR 3.9

$
0
0

Hello,

 

Is there a different way to embed fonts with Air 3.9 or FB 4.7? I've recently upgrading and I am experience tempremental results with embedding fonts.

 

With FB 4.6 and Air 3.7 the following works fine -

 

[Embed(source="/assets/fonts/SEGOEUIL.TTF", fontName="Segoe UI Light", mimeType="application/x-font-truetype")]

                    public static var EverydayFont:Class;

 

 

                                        var textFormat:TextFormat = new TextFormat();

                                        var mainFont:Font = new EverydayFont();

                                        textFormat.font = mainFont.fontName;

                              var textfield:TextField = new TextField();

                              textfield.mouseEnabled = false;

                              textfield.selectable = false;

  textfield.defaultTextFormat = textFormat;

                              textfield.multiline = false;

                              textfield.border = true;

                              textfield.embedFonts = embedFont;

                              textfield.width = width;

  textfield.antiAliasType = antiAliasStyle;

                              textfield.htmlText = label;

 

 

However now with the latest versions the text box is just blank..??


Viewing all articles
Browse latest Browse all 2954

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>