| Package | com.nocircleno.graffiti.tools |
| Class | public class TextSettings |
| Inheritance | TextSettings Object |
| Language Version : | ActionScript 3.0 |
| Runtime Versions : | AIR 1.0, Flash Player 10 - AIR 1.5 |
| Property | Defined By | ||
|---|---|---|---|
| backgroundColor : int | TextSettings | ||
| borderColor : int | TextSettings | ||
| embeddedFont : Boolean [read-only]
Is the font used an embedded font. | TextSettings | ||
| font : Font | TextSettings | ||
| textFormat : TextFormat | TextSettings | ||
| Method | Defined By | ||
|---|---|---|---|
TextSettings(font:Font, textFormat:TextFormat, backgroundColor:int = -1, borderColor:int = -1)
The TextSettings constructor. | TextSettings | ||
The clone method will return a new instance of the TextSettings. | TextSettings | ||
| backgroundColor | property |
backgroundColor:int [read-write] public function get backgroundColor():int public function set backgroundColor(value:int):void| borderColor | property |
borderColor:int [read-write] public function get borderColor():int public function set borderColor(value:int):void| embeddedFont | property |
embeddedFont:Boolean [read-only] Is the font used an embedded font.
public function get embeddedFont():Boolean| font | property |
font:Font [read-write] public function get font():Font public function set font(value:Font):void| textFormat | property |
textFormat:TextFormat [read-write] public function get textFormat():TextFormat public function set textFormat(value:TextFormat):void| TextSettings | () | Constructor |
public function TextSettings(font:Font, textFormat:TextFormat, backgroundColor:int = -1, borderColor:int = -1)
The TextSettings constructor.
font:Font — Font object used for text.
| |
textFormat:TextFormat — TextFormat Object used to display Text.
| |
backgroundColor:int (default = -1) — Background Color used for the text, set to -1 for no background.
| |
borderColor:int (default = -1) — Border Color used for the text, set to -1 for no border.
|
var allFonts:Array = Font.enumerateFonts(true);
allFonts.sortOn("fontName", Array.CASEINSENSITIVE);
var fmt:TextFormat = new TextFormat();
fmt.size = 22;
fmt.color = 0x000000;
var textSettings:TextSettings = new TextSettings(Font(allFonts[0]), fmt, -1, 0xFF0000);
| clone | () | method |
public function clone():TextSettings
The clone method will return a new instance of the TextSettings.
TextSettings — Returns new TextSettings with all the same settings.
|