Packagenet.duncanhall.components
Classpublic class TextButton
InheritanceTextButton Inheritance flash.display.SimpleButton



Public Properties
 PropertyDefined By
  downTxtFmt : TextFormat
The TextFormat used to style the button when a MouseEvent.MOUSE_DOWN event is dispatched.
TextButton
  height : Number
[override] [read-only] The height of the text in the current state.
TextButton
  overTxtFmt : TextFormat
The TextFormat used to style the button when a MouseEvent.MOUSE_OVER event is dispatched.
TextButton
  text : String
The text value that the button displays.
TextButton
  upTxtFmt : TextFormat
The TextFormat used to style the button when a MouseEvent.MOUSE_UP event is dispatched.
TextButton
  width : Number
[override] [read-only] The width of the text in the current state.
TextButton
Public Methods
 MethodDefined By
  
TextButton(text:String, upTxtFmt:TextFormat = null, overTxtFmt:TextFormat = null, downTxtFmt:TextFormat = null, embedFonts:Boolean = false)
Creates a new TextButton instance.
TextButton
Property Detail
downTxtFmtproperty
downTxtFmt:TextFormat

The TextFormat used to style the button when a MouseEvent.MOUSE_DOWN event is dispatched.


Implementation
    public function get downTxtFmt():TextFormat
    public function set downTxtFmt(value:TextFormat):void
heightproperty 
height:Number  [read-only] [override]

The height of the text in the current state.


Implementation
    public function get height():Number
overTxtFmtproperty 
overTxtFmt:TextFormat

The TextFormat used to style the button when a MouseEvent.MOUSE_OVER event is dispatched.


Implementation
    public function get overTxtFmt():TextFormat
    public function set overTxtFmt(value:TextFormat):void
textproperty 
text:String

The text value that the button displays.


Implementation
    public function get text():String
    public function set text(value:String):void
upTxtFmtproperty 
upTxtFmt:TextFormat

The TextFormat used to style the button when a MouseEvent.MOUSE_UP event is dispatched. This is the default state for the button.


Implementation
    public function get upTxtFmt():TextFormat
    public function set upTxtFmt(value:TextFormat):void
widthproperty 
width:Number  [read-only] [override]

The width of the text in the current state.


Implementation
    public function get width():Number
Constructor Detail
TextButton()Constructor
public function TextButton(text:String, upTxtFmt:TextFormat = null, overTxtFmt:TextFormat = null, downTxtFmt:TextFormat = null, embedFonts:Boolean = false)

Creates a new TextButton instance.

Parameters
text:String — The text to display on the button.
 
upTxtFmt:TextFormat (default = null) — The TextFormat to use for the up state.
 
overTxtFmt:TextFormat (default = null) — The TextFormat to use for the over state.
 
downTxtFmt:TextFormat (default = null) — The TextFormat to use for the down state.
 
embedFonts:Boolean (default = false) — Whether the text should use an embedded font.