Applying Font Options in Graphs

How to:

You can modify any text that appears with a graph, including axis titles, legends, values, and other chart titles. From this tab you can select a new font and font size, choose font styles, align text, and rotate text so that it better fits the graph.


Top of page

x
Procedure: How to Change Fonts
  1. From the Graph Editor, select Font Settings. The following dialog box opens:

    Font Settings dialog box

  2. Select the font name, size, format of text objects, and enable/disable text autofitting.

    Text items in a graph include: Chart Title, Subtitle, Footnote, Axis Labels, and Legend Text. The following instructions describe the features in the dialog box from left to right starting at the top.

    Select items in the Font Settings box to change the format of the selected text object:

    • Toggle the Auto-Fit button to auto-fit the text object.
    • Use the drop-down list box to select a font size.
    • Check the Wrap box to enable or disable the wrapping of selected text objects.

      When this box is not checked, the selected text object must appear on one line.

      When this box is checked, the text can appear on multiple lines.

    • Toggle the Bold, Italic, Underline, and Shadow buttons for these effects.
    • Toggle the Left Justify, Center and Right Justify buttons for these effects.
    • Toggle the first Text button to display the text object horizontally.
    • Toggle the second Text button to rotate the text object right 90 degrees.
    • Toggle the third Text button to rotate text object left 90 degrees.

Top of page

x
Syntax: How to Add Properties and Methods for Applying Fonts

Selections in the associated dialog boxes add the following properties and methods to the code that defines this chart:

Property

Method

Font Name

setFontName ( aGetObjectIDMethod(), true | false );

Example: setFontName ( getO1Label(), "Courier" );

Autofit

setAutofit ( aGetObjectIDMethod(), true | false );

Example: setAutofit ( getO1Label(), false );

Font Size

setFontSizeVC ( aGetObjectIDMethod(), value );

Example: setFontSizeVC ( getO1Label(), 1410 );

Wrap

setTextWrap ( aGetObjectIDMethod(), true | false );

Example: setTextWrap ( getO1Label(), true );

Font Style

setFontStyle ( aGetObjectIDMethod(), value );

Example: setFontStyle( getO1Label(), 7 );

Shadow

setShadowDisplay (aGetObjectIDMethod(), true|false );

Example: setShadowDisplay ( getO1Label(), true );

Horizontal Justification

setTextJustHoriz ( aGetObjectIDMethod(), value );

Example: setTextJustHoriz(getO1Label(),2);

Text Rotation

setTextRotation ( aGetObjectIDMethod(), value );

Example: setTextRotation ( getO1Label(), 1 );

Note: The aGetObjectIDMethod() is not a Graph Editor method. It is a notation convention used in this document to indicate one of the methods that returns an object ID. The Editor chooses the appropriate method based on the object that is selected in the chart. For example, the getO1Label() method is used if the O1 Axis Label is selected in the chart.


WebFOCUS