
TextFormat.bold Property
This is the Title of the Book, eMatter Edition
Copyright © 2007 O’Reilly & Associates, Inc. All rights reserved.
Alphabetical Language Reference
|
891
The default blockIndent value (as contained in the TextFormat object returned by
TextField.getTextFormat()) for a text field that contains text is 0. For a text field without
any text, the
blockIndent value is null. For a completely new TextFormat object, it is also
null, indicating that blockIndent will not be set when the format is applied to a text field:
trace(anyUnformattedField_txt.getTextFormat().blockIndent); // Displays: 0
var format = new TextFormat();
trace(format.blockIndent); // Displays: "null"
See Also
TextField.wordWrap, TextFormat.align, TextFormat.indent, TextFormat.leftMargin,
TextFormat.rightMargin
TextFormat.bold Property
Boolean; specifies bold character display
Flash 6
read/write
theFormat.bold
Description
The Boolean bold property specifies whether characters are displayed in a bold typeface
(
true) or a regular (nonbold) typeface (false).
To set bolding for an entire text field, invoke TextField.setTextFormat() without specifying
any index arguments:
this.createTextField("theField_txt", 1, 0, 0, 200, 20);
theField_txt.border = true;
theField_txt.text = "Press any key."
// Create a TextFormat object
format = new TextFormat();
format.bold = true;
// Bold the whole field
theField_txt.setTextFormat(format);
To set bolding ...