All options or statements
that define text strings have supporting text options that enable
you to set the color and font properties of the text. The following
table shows some of the supporting text options that are available:
|
|
|
|
|
|
|
|
|
|
|
layout or axis statements
|
|
|
|
|
The supporting text
options all have similar syntax:
supporting-text-option = style-element | style-element ( text-options ) | ( text-options )
All
supporting-text-options use a style element to determine their default characteristics.
Thus, when a different ODS style is applied to a graph, you might
see different fonts, font sizes, font weights, and font styles used
for various pieces of text in the graph.
See Attributes as Collections of Related Options for a full
discussion of how style elements and override options work.
Any text that you add
to the graph can have the following properties for the
text-options:
|
|
|
|
|
(color=GraphLabelText:color)
|
|
" font-name " | style-reference
|
(family=GraphLabelText:FontFamily)
|
|
dimension | style-reference
|
(size=GraphLabelText:FontSize)
|
|
NORMAL | BOLD | style-reference
|
(weight=GraphLabelText:FontWeight)
|
|
NORMAL | ITALIC | style-reference
|
(style=GraphLabelText:FontStyle)
|
Several style elements
affect text in different parts of a graph. Each style element defines
attributes for all of its available text options. The following table
shows some of the style elements that are available for setting text
attributes:
|
|
|
Used for all titles
of the graph. Typically uses the largest font size among fonts in
the graph.
|
|
Used for all footnotes.
Typically uses a smaller font size than the titles. Sometime footnotes
are italicized.
|
|
Used for axis labels
and legend titles. Generally uses a smaller font size than titles.
|
|
Used for axis tick values
and legend entries. Generally uses a smaller font size than labels.
|
|
Used for text where
minimum size is necessary (such as point labels).
|
|
Used for adding special
glyphs (for example α , ±, € ) to text in the graph.
|
|
Default font for text
that is added as annotation (using the ODS Graphics Editor).
|
For example, to specify
that axis labels should have the same text properties as axis tick
values, you could specify the following:
layout overlay / xaxisopts=( labelattrs=GraphValueText )
yaxisopts=( labelattrs=GraphValueText );
Style elements can also
be used to modify the display of grouped data. For example, by default,
the text color of data labels for grouped markers in a scatter plot
changes to match the marker color for each group value. To specify
that grouped data labels should use the same color as non-grouped
data labels, you could specify the following:
scatterplot x=height y=weight / group=age datalabel=name
datalabelattrs=( color=GraphDataText:Color ) ;
To ensure that a footnote
is displayed in bold italics, you could specify the following:
entryfootnote "Study conducted in 2007" /
textattrs=( weight=bold style=italic ) ;
Because the other font
properties are not overridden in this example, they are obtained from
the GraphFootnoteText style element.