Skip to main content
Known Participant
February 17, 2009
Question

Styles of embedded fonts and their usage

  • February 17, 2009
  • 1 reply
  • 559 views
When we embed a font in Flex, we can define which style of the font we want to have. So if we set the property "fontWeight" to "bold", the font manager (or the compiler?) will look for the bold font from the file, embed it and use it with text defined as bold.


Sometimes the different styles of one font are defined in different files, and often they are not defined correctly in the font file. For example, you can have a font file myfont-bold.ttf, which defines the bold style of myfont, but in the ttf file, the font is not defined as bold, but as normal (don't know if this is clear). In this case, if I set the fontWeight property to bold while embedding the font, the compiler will give an error message, which is right.


Now my question is: is there a way to tell the compiler to embed the 'normal' font from a file, but use it for bold text?

Generally it would be nice if we could define which font style to take from a font file and for which text style to use it. Does it make sense?


Haykel Ben Jemia

Allmas
Web & RIA Development
http://www.allmas-tn.com



This topic has been closed for replies.

1 reply

Participating Frequently
February 18, 2009
Hi Haykel,

Right now you'd have to modify the font. It's a known issue with Flex that has been logged. I am hoping to modify this scenario so that it is only a compiler warning but to allow the font to be embedded with the specified style regardless of what the font file describes itself as.

Pete