Developing Flash Lite 2.x and 3.0 Applications

Font rendering methods in Flash Lite

Flash Lite can render text field fonts in any of the following ways:

Use fonts that are available on the device You can apply a font to a text field that you know is available on the device, or you specify one of the three generic device fonts (_sans, _serif, or _typewriter) that are available in the Font pop-up menu. If you select a generic device font, Flash Lite tries to match the selected generic font to a font on the device at run time (for example, _sans is mapped to a sans serif font, if available).

Render the font as a bitmap Flash Lite renders bitmap text by aligning font outlines to pixel boundaries, which makes text readable at small point sizes (such as 10 points or smaller). This option requires that you include font outlines in the published SWF file for the selected font. (See Embedding font outlines in SWF files.)

Render the font as anti-aliased vectors Flash Lite renders anti-aliased text using vector-based representations of font outlines, which you embed in the published SWF file. (See Embedding font outlines in SWF files.)

You select a font rendering method for a text field using the Font Rendering Method pop-up menu located in the Property inspector. The Font Rendering Method pop-up menu contains five rendering options; however, only three of those are available to Flash Lite developers. The other two methods (Anti-Alias For Readability and Custom Anti-Alias) are available only to applications that are targeting Flash Player 8 or later on desktop computers.

Below are some guidelines to consider when you choose between anti-aliased, bitmap, and device text:

  • If you're using embedded fonts with dynamic or input text fields, embed the outlines only for the characters that you need to display. This will help to reduce file size. For example, if you're using an input text field to capture a user's age (a number), include only the font outline for number characters (0-9). In this case, consider restricting the character input to numbers (see Font rendering methods in Flash Lite).
  • The Adobe Device Central emulator does not emulate device fonts, unless you have the same fonts installed on the computer that you're using to develop the content. Therefore, the layout and appearance of your device text field might be different in the emulator than on the device.
  • If you apply one of the generic device font faces (_sans, _serif, or _typewriter), Flash Lite tries to find a similar font on the device to display the text. However, because mobile devices typically have fewer fonts and font styles than a desktop computer, a font such as _sans might not map to a sans serif font. You must test the application on each target device to determine the proper font settings.

Anti-aliased text in Flash Lite is, essentially, a complex vector shape. Like any vector shape, it takes some processing power to render. Because processing speed on most devices is relatively slow, animating a lot of anti-aliased text may degrade application performance. To improve performance, try temporarily lowering the Flash Lite player's rendering quality during the animation, and then returning it to the higher rendering quality when the animation is complete.