Embedding bold font in AS3 Flash dynamic field

11,249

Solution 1

The easiest way to fix this problem is to create a set of textfields off screen. Each field will handle the embedding for a single font and weight combination that you need. So, for example, if you need regular, bold, italic and both bold and italic for a single font, they you will have 4 textfields - each with embedding turned on, and the characters you need selected.

Then you can simply turn on font embedding for any other textfield and it will be able to use all four styles (of that font).

Solution 2

I tried changing every instance to the embedded version font with no success. I WAS however, able to use the solution suggested on the Adobe Forum here:

http://forums.adobe.com/thread/716363

Instead of using myTextFieldInstance.text, use myTextFieldInstance.htmlText and specify "<b>" + yourStringValue + "</b>" during assignment. While kludgey to the max, it was an easy solution to the problem.

Share:
11,249
shibbydoo
Author by

shibbydoo

Interactive Designer/Developer

Updated on June 11, 2022

Comments

  • shibbydoo
    shibbydoo almost 2 years

    I have already googled and read a lot of different topics relating to this problem, but still cant solve mine. I have this dynamic text field in a movieclip, and I embeded upper case, lower case and numbers. I exported that movieclip, then used it in my class and it's loading data from xml.

    However, after I embedded the bold fonts, it stopped displaying data from xml, if I use regular, it's fine. Then I created a font symbol and add the bold font in the library, it still doesn't give me anything.

    Does anyone know how to solve this problem?

    thanks.