Font that specified the font name, size, style and whether or not embed.
public function ASFont(name:String = "Tahoma", size:Number = 11, bold:Boolean = false, italic:Boolean = false, underline:Boolean = false, embedFontsOrAdvancedPros:* = null)
Create a font.
Parameters
| name:String (default = "Tahoma") — a boolean to indicate whether or not embedFonts or
a ASFontAdvProperties instance.
|
| |
| size:Number (default = 11) |
| |
| bold:Boolean (default = false) |
| |
| italic:Boolean (default = false) |
| |
| underline:Boolean (default = false) |
| |
| embedFontsOrAdvancedPros:* (default = null) |
See also
public function apply(textField:TextField, beginIndex:int = -1, endIndex:int = -1):void
Applys the font to the specified text field.
Parameters
| textField:TextField — the text filed to be applied font.
|
| |
| beginIndex:int (default = -1) — The zero-based index position specifying the first character of the desired range of text.
|
| |
| endIndex:int (default = -1) — The zero-based index position specifying the last character of the desired range of text.
|
public function changeBold(bold:Boolean):ASFontParameters
Returns
public function changeItalic(italic:Boolean):ASFontParameters
Returns
public function changeName(name:String):ASFontParameters
Returns
public function changeSize(size:int):ASFontParameters
Returns
public function changeUnderline(underline:Boolean):ASFontParameters
Returns
public function computeTextSize(text:String, includeGutters:Boolean = true):IntDimension
Computes text size with this font.
Parameters
| text:String — the text to be compute
|
| |
| includeGutters:Boolean (default = true) |
Returns
See also
public function getAdvancedProperties():ASFontAdvProperties
Returns
public function getName():String
Returns
public function getSize():uint
Returns
public function getTextFormat():TextFormat
Return a new text format that contains the font properties.
Returns
| TextFormat — a new text format.
|
public function isBold():Boolean
Returns
public function isEmbedFonts():Boolean
Returns
public function isItalic():Boolean
Returns
public function isUnderline():Boolean
Returns
public function toString():String
Returns