1242 ActionScript classes
var myformat:TextFormat = new TextFormat();
myformat.size = 20;
mytext.text = "This is my first text field object text";
mytext.setTextFormat(myformat);
tabStops (TextFormat.tabStops property)
public tabStops : Array
Specifies custom tab stops as an array of non-negative integers. Each tab stop is specified in
pixels. If custom tab stops are not specified (
null
), the default tab stop is 4 (average character
width).
Availability:
ActionScript 1.0; Flash Player 6
Example
The following example creates two text fields, one with tab stops every 40 pixels, and the
other with tab stops every 75 pixels.
this.createTextField("mytext",1,100,100,400,100);
mytext.border = true;
var myformat:TextFormat = new TextFormat();
myformat.tabStops = [40,80,120,160];
mytext.text = "A\tB\tC\tD"; // \t is the tab stop character
mytext.setTextFormat(myformat);
this.createTextField("mytext2",2,100,220,400,100);
mytext2.border = true;
var myformat2:TextFormat = new TextFormat();
myformat2.tabStops = [75,150,225,300];
mytext2.text ="A\tB\tC\tD";
mytext2.setTextFormat(myformat2);
target (TextFormat.target property)
public target : String
Indicates the target window where the hyperlink is displayed. If the target window is an empty
string, the text is displayed in the default target window
_self
. You can choose a custom
name or one of the following four names:
_self
specifies the current frame in the current
window,
_blank
specifies a new window,
_parent
specifies the parent of the current frame,
and
_top
specifies the top-level frame in the current window. If the
TextFormat.url
property is an empty string or
null
, you can get or set this property, but the property will
have no effect.
Summary of Contents for FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
Page 1: ...ActionScript 2 0 Language Reference ...
Page 1352: ...1352 ActionScript classes ...