Package com.bit101.components
Class public class Label
Inheritance Label InheritanceComponent Inheritance flash.display.Sprite



Public Properties
  Property Defined By
    autoSize : Boolean
Gets / sets whether or not this Label will autosize.
Label
  Inherited enabled : Boolean
Sets/gets whether this component is enabled or not.
Component
  Inherited height : Number
[override] Sets/gets the height of the component.
Component
  Inherited tag : int
Sets/gets in integer that can identify the component.
Component
    text : String
Gets / sets the text of this Label.
Label
    textField : TextField
[read-only] Gets the internal TextField of the label if you need to do further customization of it.
Label
  Inherited width : Number
[override] Sets/gets the width of the component.
Component
  Inherited x : Number
[override] [write-only] Overrides the setter for x to always place the component on a whole pixel.
Component
  Inherited y : Number
[override] [write-only] Overrides the setter for y to always place the component on a whole pixel.
Component
Protected Properties
  Property Defined By
    _autoSize : Boolean = true
Label
  Inherited _enabled : Boolean = true
Component
  Inherited _height : Number = 0
Component
  Inherited Ronda : Class
Component
  Inherited _tag : int = -1
Component
    _text : String
Label
    _tf : TextField
Label
  Inherited _width : Number = 0
Component
Public Methods
  Method Defined By
   
Label(parent:DisplayObjectContainer = null, xpos:Number = 0, ypos:Number = 0, text:String)
Constructor
Label
   
draw():void
[override] Draws the visual ui of the component.
Label
  Inherited
initStage(stage:Stage):void
[static] Utility method to set up usual stage align and scaling.
Component
  Inherited
move(xpos:Number, ypos:Number):void
Moves the component to the specified position.
Component
  Inherited
setSize(w:Number, h:Number):void
Sets the size of the component.
Component
Protected Methods
  Method Defined By
   
addChildren():void
[override] Creates and adds the child display objects of this component.
Label
  Inherited
getShadow(dist:Number, knockout:Boolean = false):DropShadowFilter
DropShadowFilter factory method, used in many of the components.
Component
   
init():void
[override] Initializes the component.
Label
  Inherited
invalidate():void
Marks the component to be redrawn on the next frame.
Component
  Inherited
onInvalidate(event:Event):void
Called one frame after invalidate is called.
Component
Public Constants
  Constant Defined By
  Inherited DRAW : String = draw
[static]
Component
Property Detail
_autoSize property
protected var _autoSize:Boolean = true

_text property  
protected var _text:String

_tf property  
protected var _tf:TextField

autoSize property  
autoSize:Boolean

Gets / sets whether or not this Label will autosize.


Implementation
    public function get autoSize():Boolean
    public function set autoSize(value:Boolean):void
text property  
text:String

Gets / sets the text of this Label.


Implementation
    public function get text():String
    public function set text(value:String):void
textField property  
textField:TextField  [read-only]

Gets the internal TextField of the label if you need to do further customization of it.


Implementation
    public function get textField():TextField
Constructor Detail
Label () Constructor
public function Label(parent:DisplayObjectContainer = null, xpos:Number = 0, ypos:Number = 0, text:String)

Constructor

Parameters
parent:DisplayObjectContainer (default = null) — The parent DisplayObjectContainer on which to add this Label.
 
xpos:Number (default = 0) — The x position to place this component.
 
ypos:Number (default = 0) — The y position to place this component.
 
text:String — The string to use as the initial text in this component.
Method Detail
addChildren () method
override protected function addChildren():void

Creates and adds the child display objects of this component.

draw () method  
override public function draw():void

Draws the visual ui of the component.

init () method  
override protected function init():void

Initializes the component.