The PowerBuilder class grDispAttr is used to specify the appearance of text objects on a graph. There are grDispAttr objects for graph Titles, Legends, Pie Graph text, and two (DispAttr and LabelDispAttr) for each of the three axes (Category, Series, and Value) in a graph.
To refer to a property of a grDispAttr property, use this syntax:
graphcontrolname.axisname.grdispattrname.property
For example:
gr_1.Series.DispAttr.Italic gr_1.Category.LabelDispAttr.DisplayExpression
A grDispAttr object has no events.
grDispAttr property |
Datatype |
Description |
---|---|---|
Alignment (enumerated) |
Specifies the alignment of the text. Values are: Center! Justify! Left! Right! |
|
Boolean |
Specifies whether the text element should be autosized according to the amount of text being displayed. Values are: TRUE -- Autosize. FALSE -- Do not autosize. |
|
Long |
Specifies the numeric value of the background color: -2 to 16,777,215. For more information about color, see the section called “RGB” in PowerScript Reference. |
|
ClassDefinition |
PowerObject |
An object of type PowerObject containing information about the class definition of the object or control. |
String |
An expression whose value is the label for the graph component. The default expression is the property containing the text for the graph component. The expression can include the text property and add other variable text. |
|
Integer |
Specifies the rotation for the baseline of the text in tenths of a degree. 0 is horizontal. A value of 900 rotates the text 90 degrees; a value of 2700 rotates the text 270 degrees. |
|
String |
Specifies a typeface name (for example, arial or courier) to use for the text. |
|
FillPattern (enumerated) |
Specifies the fill pattern for the text. Values are: BDiagonal! Diamond! FDiagonal! Horizontal! Solid! Square! Vertical! FDiagonal! is lines going from the lower-left to the upper-right. BDiagonal! is lines going from the upper-left to the lower right. |
|
FontCharSet (enumerated) |
Specifies the font character set to be used. For a complete list of possible values, see the list of properties for the FontCharSet variable on the Enumerated tab page of the Browser. |
|
FontFamily (enumerated) |
Specifies the font family (type style) for the text. Values are: AnyFont! Decorative! Modern! Roman! Script! Swiss! |
|
FontPitch (enumerated) |
Specifies the pitch (character spacing) for the text. Values are: Default! Fixed! Variable! |
|
String |
Specifies the display format for the text. |
|
Boolean |
Specifies whether the text is italic. Values are: TRUE -- Text is italic. FALSE -- Text is not italic. |
|
Long |
Specifies the color of the text. The color is a numeric value: -2 to 16,777,215. For more information about color, see the section called “RGB” in PowerScript Reference. |
|
Integer |
Specifies the point size of the text. For backward compatibility, the size is stored as a negative number; for example, 10-point text size is stored as -10. |
|
Boolean |
Specifies whether the text is underlined. Values are: TRUE -- Text is underlined. FALSE -- Text is not underlined. |
|
Integer |
Specifies the stroke weight of the text. Sample values are 400 for normal or 700 for bold. |