MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference page 1235

Actionscript 2.0 language reference
Table of Contents

Advertisement

The
and
width
height
and
textFieldHeight
required for a text field object to display the entire text string. Text fields have a 2-pixel-wide
gutter around them, so the value of
likewise, the value of
If you are creating a text field based on the text metrics, use
and
height
textFieldWidth
The following figure illustrates these measurements.
When setting up your TextFormat object, set all the attributes exactly as they will be set for
the creation of the text field, including font name, font size, and leading. The default value for
leading is 2.
Availability: ActionScript 1.0; Flash Player 6 - The width parameter is supported in Flash
Player 7.
Parameters
- A string.
text:String
[optional] - A number that represents the width, in pixels, at which the
width:Number
specified text should wrap.
Returns
- An object with the properties
Object
.
textFieldWidth
measurements provide the width and height of the text string. The
measurements provide the height and width
textFieldWidth
textFieldHeight
is always equal to the value of
textFieldWidth
rather than
width
is equal the value of
textFieldHeight
.
width
,
,
,
height
ascent
+ 4;
height
+ 4.
width
rather than
,
descent
textFieldHeight
TextFormat
,
1235

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Flash 8

Table of Contents