Packagekm.components
Classpublic class BitmapLabel
InheritanceBitmapLabel Inheritance UIComponent Inheritance flash.display.Sprite

The BitmapLabel component class.
The BitmapLabel class has a bitmap text instead of a normal dynamic text to allow for text rotation.
A lot of the properties of the BitmapLabel class are similar to those of the flash.text.TextField class.
It's recommended to study information on that class if you want to know more about them.


Example
import km.components.*;

var l:BitmapLabel = new BitmapLabel();
l.setSize(20,120);
l.move(20,20);

l.icon = new BitmapData(8, 8, false, 0xc0b0a0);
l.textRotation = 270;
l.labelPlacement = 'top';
l.align = 'center';
l.valign = 'bottom';
l.text = 'Label';

addChild(l);

See also

flash.text.TextField


Public Properties
 PropertyDefined by
  align : String
Horizontal alignment within the bounding box.
Possible values are 'left', 'right' and 'center'.
BitmapLabel
  background : Boolean
BitmapLabel
  backgroundColor : uint
BitmapLabel
  defaultTextFormat : TextFormat
BitmapLabel
 Inheritedduotone : Array
The duotone property can be used to convert the colors of the component into duotone.
UIComponent
  embedFonts : Boolean
BitmapLabel
 Inheritedenabled : Boolean
Specifies if the component is enabled.
If a component is disabled, it will be turned into grayscale and become partly transparent.
UIComponent
 Inheritedheight : Number
UIComponent
  htmlText : String
BitmapLabel
  icon : BitmapData
BitmapLabel
  labelPlacement : String
Placement of the label text.
Possible values are 'left', 'right', 'top' and 'bottom'.
BitmapLabel
  length : int
[read-only]
BitmapLabel
  text : String
BitmapLabel
  textColor : uint
BitmapLabel
  textRotation : int
Rotation of the text.
Possible values are 0, 90, 180 and 270.
BitmapLabel
 InheritedtoolTip : String
Text to use as toolTip when ToolTip is enabled.
UIComponent
  valign : String
Vertical alignment within the bounding box.
Possible values are 'top', 'bottom' and 'center'.
BitmapLabel
 Inheritedwidth : Number
UIComponent
  wordWrap : Boolean
BitmapLabel
 Inheritedx : Number
UIComponent
 Inheritedy : Number
UIComponent
Public Methods
 MethodDefined by
  
The default size of a bitmap label is 120 x 20 pixels.
BitmapLabel
 Inherited
clone():*
Returns a clone of the component.
The skin of the component is cloned but other things like the text of a label or the items of a list aren't.
UIComponent
 Inherited
move(x:int, y:int, animationMode:int = 0, animationFrames:int = 12, easeInOut:Boolean = false):void
Moves the component to the specified coordinates.
UIComponent
 Inherited
setProperties(o:Object):void
Sets a number of properties at once.
UIComponent
 Inherited
setSize(w:int, h:int):void
Sets the size width and height.
UIComponent
Events
 EventSummaryDefined by
 Inherited The animationComplete event is broadcasted when an animated move is completed.UIComponent
Property detail
alignproperty
align:String  [read-write]

Horizontal alignment within the bounding box.
Possible values are 'left', 'right' and 'center'.

The default value is 'left'.

Implementation
    public function get align():String
    public function set align(value:String):void
backgroundproperty 
background:Boolean  [read-write]

Implementation
    public function get background():Boolean
    public function set background(value:Boolean):void
backgroundColorproperty 
backgroundColor:uint  [read-write]

Implementation
    public function get backgroundColor():uint
    public function set backgroundColor(value:uint):void
defaultTextFormatproperty 
defaultTextFormat:TextFormat  [read-write]

Implementation
    public function get defaultTextFormat():TextFormat
    public function set defaultTextFormat(value:TextFormat):void
embedFontsproperty 
embedFonts:Boolean  [read-write]

Implementation
    public function get embedFonts():Boolean
    public function set embedFonts(value:Boolean):void
htmlTextproperty 
htmlText:String  [read-write]

Implementation
    public function get htmlText():String
    public function set htmlText(value:String):void
iconproperty 
icon:BitmapData  [read-write]

Implementation
    public function get icon():BitmapData
    public function set icon(value:BitmapData):void
labelPlacementproperty 
labelPlacement:String  [read-write]

Placement of the label text.
Possible values are 'left', 'right', 'top' and 'bottom'.

The default value is 'right'.

Implementation
    public function get labelPlacement():String
    public function set labelPlacement(value:String):void
lengthproperty 
length:int  [read-only]

Implementation
    public function get length():int
textproperty 
text:String  [read-write]

Implementation
    public function get text():String
    public function set text(value:String):void
textColorproperty 
textColor:uint  [read-write]

Implementation
    public function get textColor():uint
    public function set textColor(value:uint):void
textRotationproperty 
textRotation:int  [read-write]

Rotation of the text.
Possible values are 0, 90, 180 and 270.

Implementation
    public function get textRotation():int
    public function set textRotation(value:int):void
valignproperty 
valign:String  [read-write]

Vertical alignment within the bounding box.
Possible values are 'top', 'bottom' and 'center'.

The default value is 'center'.

Implementation
    public function get valign():String
    public function set valign(value:String):void
wordWrapproperty 
wordWrap:Boolean  [read-write]

Implementation
    public function get wordWrap():Boolean
    public function set wordWrap(value:Boolean):void
Constructor detail
BitmapLabel()constructor
public function BitmapLabel()

The default size of a bitmap label is 120 x 20 pixels.