There are now two types of font embedding available to both Flash (CS4) and Flex 3 and 4. These are DefineFont3 (classic), and DefineFont4 (supporting CFF and the new text engine.)
In Flash, Flex 2 and 3 you’d traditionally embed fonts for use in the TextField class, whether that’s a vanilla TextField, or a component that uses the TextField class and has been set to use embedded fonts. This is DefineFont3 embedding. The steps are usually:
- Embed fonts in a SWF using the Flash IDE or the [Embed()] tag in Flex.
- Set myTextField.embedFonts = true; (or setStyle(“embedFonts”,true) for a component.)
- Either set myTextField.defaultTextFormat, use setTextFormat(), or setStyle().
- Set the text with .text or .htmlText (using CSS or the font tag).
- March 16, 2009
- 13 Comments