1246 ActionScript classes
TextRenderer (flash.text.TextRenderer)
Object
|
+-flash.text.TextRenderer
public class
TextRenderer
extends Object
The TextRenderer class provides functionality for the advanced anti-aliasing capability of
embedded fonts. Advanced anti-aliasing allows font faces to render at very high quality at
small sizes. Use advanced anti-aliasing with applications that have a lot of small text.
Macromedia does not recommend using advanced anti-aliasing for very large fonts (larger
than 48 points). Advanced anti-aliasing is available in Flash Player 8 only.
To set advanced anti-aliasing on a text field, set the
antiAliasType
property of the TextField
instance. The following example requires a shared font in the library with a linkage identifier
named,
"CustomFont"
.
var txtFormat:TextFormat = new TextFormat();
txtFormat.font = "CustomFont";
var label:TextField = this.createTextField("label",
this.getNextHighestDepth(), 10, 10, 200, 20);
label.setNewTextFormat(txtFormat);
label.text = "Hello World";
label.embedFonts = true;
label.antiAliasType = "advanced";
Advanced anti-aliasing provides continuous stroke modulation (CSM), which is continuous
modulation of both stroke weight and edge sharpness. As an advanced feature, you can use the
setAdvancedAntialiasingTable()
method to define settings for specific typefaces and font
sizes.
Availability:
ActionScript 1.0; Flash Player 8
See also
antiAliasType (TextField.antiAliasType property)
Property summary
Modifiers
Property
Description
static
maxLevel
:Number
The adaptively sampled distance fields (ADFs) quality
level for advanced anti-aliasing.
Summary of Contents for FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
Page 1: ...ActionScript 2 0 Language Reference ...
Page 1352: ...1352 ActionScript classes ...