Text.gettextattr() - MACROMEDIA FLASH MX 2004-FLASH JAVASCRIPT DICTIONARY Manual

Flash javascript dictionary
Hide thumbs Also See for FLASH MX 2004-FLASH JAVASCRIPT DICTIONARY:
Table of Contents

Advertisement

Description
Property; a string that consists of delimited integers that correspond to the items that can be
selected in the Character Options dialog box. This property works only with dynamic or input
text; it is ignored if used with static text.
Note: This property corresponds to the XML file in the Configuration/Font Embedding folder.
Example
The following example sets the
fl.getDocumentDOM().getTimeline().layers[0].frames[0].elements[0].embedRanges
= "1|3|7";
The following example resets the property:
fl.getDocumentDOM().getTimeline().layers[0].frames[0].elements[0].embedRanges
= "";

text.getTextAttr()

Availability
Flash MX 2004.
Usage
text.getTextAttr(attrName [, startIndex [, endIndex]])
Parameters
A string that specifies the name of the TextAttrs object property to be returned.
attrName
Note: For a list of possible values for
An integer that is the index of first character. This parameter is optional.
startIndex
An integer that specifies the end of the range of text, which starts with
endIndex
and goes up to, but does including,
Returns
The value of the attribute specified in the
Description
Method; retrieves the attribute specified by the
optional
startIndex
range, Flash returns
entire text range. If you specify only
position. If you specify both
goes up to, but not including,
Example
The following example gets the font size of the currently selected text field and shows it:
var TheTextSize = fl.getDocumentDOM().selection[0].getTextAttr("size");
fl.trace(TheTextSize);
embedRanges
attrName
endIndex
attrName
and
parameters. If the attribute is not consistent for the specified
endIndex
. If you specify
undefined
startIndex
and
startIndex
.
endIndex
property to
"1|3|7"
, see
Property summary for the TextAttrs
. This parameter is optional.
parameter.
parameter for the text identified by the
attrName
and
startIndex
endIndex
, the range used is a single character at that
, the range starts from
endIndex
:
object.
startIndex
, the method uses the
startIndex
Text object
and
311

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH MX 2004-FLASH JAVASCRIPT DICTIONARY and is the answer not in the manual?

This manual is also suitable for:

Flash mx 2004 - actionscript

Table of Contents