# Issues with embedding fonts in AS3

**URL:** <https://forum.kirupa.com/t/issues-with-embedding-fonts-in-as3/299396>\
**Category:** flash\
**Created:** [November 4, 2009, 12:24pm UTC](https://forum.kirupa.com/t/issues-with-embedding-fonts-in-as3/299396 "2009-11-04T12:24:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![baradas](https://avatars.discourse-cdn.com/v4/letter/b/b487fb/32.png) [@baradas](https://forum.kirupa.com/u/baradas)\
**Post date:** [November 4, 2009, 12:24pm UTC](https://forum.kirupa.com/t/issues-with-embedding-fonts-in-as3/299396/1 "2009-11-04T12:24:24Z")

</div>

Hi,  
I am currently using AS3 with CS4 and am a newbie to flash. I want to represent superscript and subscript characters in a text area and one way to do that is to use GG Superscript and GG Subscript fonts. When I include the fonts in my system fonts I am able to see the rendered characters in the text area. However if I reference the embedded font instead of the system font I am no longer able to see the characters with the correct rendering.  
I understand there are two approaches for embedding a font  
A:

```auto

[Embed(systemFont="GG Superscript", fontName="GGS", mimeType="application/x-font")]      
private static var EMBEDDED_FONT:String;

```

or  
B: to include the font in the fla library and give it a corresponding name.

However both approaches result in failures as the text area is unable to find the embedded font. I have also set the embedFonts property to true for the textfield in the TextArea.

The htmlText to be rendered in the textArea is as follows:

```auto
ƒ(x) = ½ x<font face="GGS">2</font><br/>

```

The above htmlText doesn’t render correctly.

However if I change the htmlText to :

```auto
ƒ(x) = ½ x<font face="GG Superscript">2</font><br/>

```

This renders fine.

Please advise.
