CoreTextField
| Kind of class: | class |
|---|---|
| Inherits from: | CoreMovieClip < MovieClip |
| Known subclasses: | |
| Version: | 04/09/07 |
| Author: | Aaron Clinger, Mike Creighton |
| Classpath: | org.casaframework.textfield.CoreTextField |
| File last modified: | Monday, 09 April 2007, 16:57:37 |
CoreTextField is actually a CoreMovieClip class that uses composition to emulate the standard Flash TextField class. By doing this, it is now possible to extend TextFields where it would otherwise be impossible due to the limitations of TextField instantiation in AS 2.0. All TextField classes should extend from here.
Example:
var myText_mc:CoreTextField = CoreTextField.create(this, "text_mc", null, 250, 50); this.myText_mc.border = this.myText_mc.background = true; this.myText_mc.text = "Hello World!";
Summary
Instance properties
Instance properties inherited from CoreMovieClip
Instance methods
Instance methods inherited from CoreMovieClip
Class methods
create
static function create (
target:MovieClip,
instanceName:String,
depth:Number,
width:Number,
height:Number) : CoreTextField
Creates an empty instance of the CoreTextField class. Use this instead of a traditional
new constructor statement due to limitations of ActionScript 2.0.Parameters:
target :
Location where the TextField should be attached.
instanceName:
A unique instance name for the TextField.
depth :
[optional] The depth level where the TextField is placed; defaults to next highest open depth.
width :
A positive integer that specifies the width of the new text field.
height :
A positive integer that specifies the height of the new text field.
Returns:
Returns a reference to the created instance.
Example:
var myText_mc:CoreTextField = CoreTextField.create(this, "text_mc", null, 250, 50);