Chapter 9:
Chart Objects


 

Object IDs identify the graphic elements (objects) in a graph. A graph contains many objects, such as Gridlines, walls, risers, boxes, text, etc. Each object has a minimum of a color, pattern, and special effect. But not all objects are created equal. For instance, a grid line can be colored, but a pattern cannot be applied to it. A font attribute can be applied to a text object, but this attribute would be discarded and ignored if an area object was selected.

 

In general, you modify an object by setting attributes that define the appearance of that object in the graph. The attributes are listed in Chapter 10. The SetGraphAttr(), SetGraphAttrSL(), and SetGraphAttrSI() functions described in Chapter 7 are used to assign values to the attributes. Attributes can define the appearance of an individual object or all objects in a particular class. In some cases, they can also define the appearance of all instances of an individual object or a specific instance of a individual object.

OBJECT CLASSES

 

All objects in a graph are assigned to one of three classes:

 

Area Objects

 

Line Objects

 

Text Objects

 

The following illustration shows a very simple graph with objects that belong to each class (i.e., a riser object in the Area class, an O1-axis body in the Line class, and the O1-axis Labels in the Text class):

 

 

The object's class will help you identify the type of attributes that can be applied to it. Many attribute codes identify the type of object to which it can be applied. For example, A_AREACOLOR_RGB clearly identifies it as an attribute that can be applied to objects in the area class.

OBJECT INSTANCES

 

Some Object IDs identify multiple objects, or more precisely, multiple instances of an object in a graph. For example, there is only one O2D_RISER Object ID that identifies all risers in a graph. If there are three different series of risers in a graph and we want to modify only one series (eg. change its color), an individual riser object can be further identified by its series and, in some cases, group ID.

 

 

The Object ID specifies whether or not there can be multiple instances of the object in a single graph (e.g., O5D_LBLFOOTNOTE is a single object, O2D_RISER represents multiple instances of the riser object). For Object IDs that represent multiple instances of an object, each attribute code further identifies whether or not it can be applied to all or individual instances of the object. For example, the A_AREACOLOR attribute can define: 1) the color of all objects in the Area class when no Object ID is specified, 2) the color of all instances of an Area object (e.g., O2D_RISER) when no series or group is specified, or 3) a single instance of an object when a series and/or group ID is specified.

OBJECT ID NAMING CONVENTION

 

Object IDs are named according to the graph types in which they typically appear. Some objects can appear in any graph type and are, therefore, named as common attributes. The first three characters of the object ID identify the graph type in which it typically appears:

 

O2D_: 2D graph objects

 

O3D_: 3D graph objects

 

O5D_: Common Objects (available to all graph types)

 

OAN_: Annotation objects (squares, circles, lines, text, etc)

 

OBL_: Bubble Chart objects

 

OPI_: Pie Graph objects

 

OPL_: Polar chart objects

 

OSM_: Stock Market Chart objects

 

OSG_: Common Objects (available to all graph types)

 

OSP_: Spectral Map objects

 

OTC_: Table chart objects

OBJECT IDS AND ATTRIBUTES

 

The Object IDs also help you identify which group of attributes control the appearance of objects in the group. In general, the common attributes (A_ and ASG_) can affect the appearance of all objects. The following table identifies the attribute group that typically controls objects in each object group:

 

A2D..._: These attributes primarily control O2D_ Objects, but some O3D_ Objects also.

 

A3D..._: These attributes primarily control O3D_ Objects, but some O2D_ Objects also.

 

AAN..._: These attributes primarily control OAN_ Objects.

 

API..._: These attributes primarily control OPI_ Objects.

 

APL..._: These attributes primarily control OPL_ Objects.

 

ASG..._: These attributes primarily control OSG_ Objects.

 

ATC..._: These attributes primarily control OTC_ Objects.

Class

ObjectID

Description

Area

O2D_AREARISER

Quantitative data representation in an area chart

Line

O2D_CONNECT_STACKLINE

Line that connects stacked bars

Line

O2D_CURVE

Quantitative data series interpolation line

Line

O2D_DATALINE

Line connecting data markers of a line chart

Area

O2D_DATAMARKER

Quantitative data representation point

Text

O2D_DATATEXT

Text value of a quantitative data representation

Line

O2D_DATATEXT_CONNECTLINE

Connecting line between data text and riser/marker.

Text

O2D_DATATEXT_STACK_TOTAL

Stacked total in a stacked bar chart

Line

O2D_DIVBIPOLAR

Line dividing bipolar chart surfaces

Line

O2D_ERRORBAR

Line identifying values out of range

Line

O2D_LINR_EXP

Exponential Linear Regression Line

Line

O2D_LINR_LINE

Linear Regression Line

Line

O2D_LINR_LOG

Logrithmic Linear Regression Line

Line

O2D_LINR_NATLOG

Natural Logrithmic Linear Regression Line

Line

O2D_LINR_NPOLY

Polynomial Linear Regression Line

Text

O2D_LINR_TEXT

Formula Text associated with a Linear Regression Line

Text

O2D_MD_LABEL0...31

Multi-Dimensional Labels

Line

O2D_MEANLINE

Histogram mean line

Line

O2D_MOVAVGLINE

Quantitative data series moving average line

Line

O2D_O1_BODY

Primary Ordinal Axis Base Line

Text

O2D_O1_LABEL

Primary Ordinal Axis Label

Line

O2D_O1_MAJOR

Primary Ordinal Axis Major Grid Line

Line

O2D_O1_MINOR

Primary Ordinal Axis Minor Grid Line

Line

O2D_O1_SUPER

Primary Ordinal Axis Super Grid Line

Text

O2D_O1_TITLE

Primary Ordinal Axis Title

Line

O2D_O2_BODY

Secondary Ordinal Axis Base Line

Text

O2D_O2_LABEL

Secondary Ordinal Axis Label

Line

O2D_O2_MAJOR

Secondary Ordinal Axis Major Grid Line

Line

O2D_O2_MINOR

Secondary Ordinal Axis Minor Grid Line

Line

O2D_O2_TITLE

Secondary Ordinal Axis Title

Line

O2D_PRESDL_CONN

Pre-Series Dependent Connection Line

Line

O2D_PRESDL_CONNBRK

Pre-Series Dependent Connection Line with breaks

Line

O2D_PRESDL_STEP

Pre-Series Dependent Stair-Stepped Line

Line

O2D_PRESDL_STEPBRK

Pre-Series Dependent Stair-Stepped Line with breaks

Area

O2D_RISER

Quantitative data representation of a bar chart

Area

O2D_RISER2/3

2.5D Mode riser faces

Area

O2D_RISERSHADOW

Visual effect for bar data representation

Text

O2D_SERIES_TITLE

Series title for legends

Line

O2D_STDDEVLINE

Histogram standard deviation line(s)

Line

O2D_USERLINE1...4

User defined gridline

Line

O2D_X1_BODY

X-Axis Base Line

Text

O2D_X1_LABEL

X-Axis Label

Line

O2D_X1_MAJOR

X-Axis Major Grid Line

Line

O2D_X1_MINOR

X-Axis Minor Grid Line

Text

O2D_X1_TITLE

X-Axis Title

Line

O2D_X1_ZERO

X-Axis Zero Line

Line

O2D_Y1_BODY

Y1-Axis Base Line

Text

O2D_Y1_LABEL

Y1-Axis Label

Line

O2D_Y1_MAJOR

Y1-Axis Major Grid Line

Line

O2D_Y1_MINOR

Y1-Axis Minor Grid Line

Text

O2D_Y1_TITLE

Y1-Axis Title

Line

O2D_Y1_ZERO

Y1-Axis Zero Line

Line

O2D_Y2_BODY

Y2-Axis Base Line

Text

O2D_Y2_LABEL

Y2-Axis Label

Line

O2D_Y2_MAJOR

Y2-Axis Major Grid Line

Line

O2D_Y2_MINOR

Y2-Axis Minor Grid Line

Text

O2D_Y2_TITLE

Y2-Axis Title

Line

O2D_Y2_ZERO

Y2-Axis Zero Line

Line

O2D_Y3_BODY

Y3-Axis Base Line

Text

O2D_Y3_LABEL

Y3-Axis Label

Line

O2D_Y3_MAJOR

Y3-Axis Major Grid Line

Line

O2D_Y3_MINOR

Y3-Axis Minor Grid Line

Text

O2D_Y3_TITLE

Y3-Axis Title

Line

O2D_Y3_ZERO

Y3-Axis Zero Line

Line

O2D_Y4_BODY

Y4-Axis Base Line

Text

O2D_Y4_LABEL

Y4-Axis Label

Line

O2D_Y4_MAJOR

Y4-Axis Major Grid Line

Line

O2D_Y4_MINOR

Y4-Axis Minor Grid Line

Text

O2D_Y4_TITLE

Y4-Axis Title

Line

O2D_Y4_ZERO

Y4-Axis Zero Line

Text

O3D_COLHEADER

Text associated with a data group (column)

Text

O3D_COLHEADER_2D

2D text version of column header

Area

O3D_COLHEADER_BOX

Optional box behind O3D_COLHEADER

Text

O3D_COLTITLE

Title associated with all data groups

Text

O3D_COLTITLE_2D

2D text version of column title

Area

O3D_COLTITLE_BOX

Optional box behind O3D_COLTITLE

Text

O3D_DATALABEL

Text label used mainly for scatter graph

Area

O3D_DATALABEL_BOX

Box for O3D_DATALABEL

Area

O3D_DATAMARKER

2D Marker used for scatter graphs

Area

O3D_FLOOR1...3

Front and back faces of graph's floor

Line

O3D_FRAMEGRID_X

Tickline along x axis on graph cube/frame

Line

O3D_FRAMEGRID_Y

Tickline along y axis on graph cube/frame

Line

O3D_FRAMEGRID_Z

Tickline along z axis on graph cube/frame

Area

O3D_LASTRISERFACE

Tenth face of a riser

Area

O3D_LEFTWALL1...3

Front and back faces of graph's left wall

Text

O3D_LYHEADER

Text associated with left vertical axis (Y1)

Text

O3D_LYHEADER_2D

2D text version of left header

Text

O3D_LYHEADER_BOX

Optional box behind LYHEADER

Text

O3D_LYTITLE

Title associated with left vertical axis (Y1)

Text

O3D_LYTITLE_2D

2D text version of left title

Text

O3D_LYTITLE_BOX

Optional box behind LYTITLE

Area

O3D_NEGATIVE_FILL

In OpenGL, the transparant fill of the 3D cube for negative numbers.

Area

O3D_RIGHTWALL1...3

Front and back faces of graph's right wall

Area

O3D_RISERFACE1...9

First...Ninth face of a riser

Line

O3D_RISERGRID_X

Tickline along x axis on risers

Line

O3D_RISERGRID_Y

Tickline along y axis on risers

Line

O3D_RISERGRID_Z

Tickline along z axis on risers

Text

O3D_ROWHEADER

Text associated with a data series (row)

Text

O3D_ROWHEADER_2D

2D text version of row header

Area

O3D_ROWHEADER_BOX

Optional box behind O3D_ROWHEADER

Text

O3D_ROWTITLE

Title associated with all data series

Text

O3D_ROWTITLE_2D

2D text version of row title

Area

O3D_ROWTITLE_BOX

Optional box behind O3D_ROWTITLE

Text

O3D_RYHEADER

Text associated with right vertical axis

Text

O3D_RYHEADER_2D

2D text version of right header

Area

O3D_RYHEADER_BOX

Optional box behind O3D_RYTITLE

Text

O3D_RYTITLE

Title for right vertical axis

Text

O3D_RYTITLE_2D

2D text version of right title

Area

O3D_RYTITLE_BOX

Optional box behind O3D_RYTITLE

Line

O3D_SCATTERLINE

Line connecting scatter markers

Line

O3D_TIELINE_XX

Line connecting markers to the left wall

Line

O3D_TIELINE_YY

Line connecting markers to the floor

Line

O3D_TIELINE_ZZ

Line connecting markers to the right wall

Area

O3D_VARIABLEFACE

Any face of a variable face marker

Area

O5D_BACKGROUND

Background of a Graph

Area

O5D_FRAME

Graph Frame

Text

O5D_LBLFOOTNOTE

Chart Footnote

Text

O5D_LBLSUBTITLE

Chart Subtitle

Text

O5D_LBLTITLE

Chart Title

Annotation

OAN_ARC

Arc annotation object

Annotation

OAN_ARROW

Arrow annotation object

Annotation

OAN_BALLOON

Balloon object

Annotation

OAN_BALLOONPARA

Balloon paragraph

Annotation

OAN_DBLTBOXIN

Inside Double Text Box object

Annotation

OAN_DBLTBOXOUT

Annotation object

Annotation

OAN_ELLIPSE

Ellipse annotation object

Annotation

OAN_FREEHAND

Arrow object

Annotation

OAN_LINE

Line annotation object

Annotation

OAN_POLYGON

Polygon annotation object

Annotation

OAN_POLYLINE

Polyline annotation object

Annotation

OAN_RECTANGLE

Rectangle annotation object

Annotation

OAN_ROUNDRECT

Rounded Rectangle annotation object

Annotation

OAN_TEXT

Annotation object

Annotation

OAN_THREEDTBOXFACE

Face Of 3D Text Box object

Annotation

OAN_THREEDTBOXSIDES

Sides Of 3D Text Box object

Line

OBL_QUADRANTLINE

Quadrant Lines in a Bubble Chart

Line

OPI_BARCONNECT

Line that connects pie to bar in pie bar

Line

OPI_FEELER

Line drawn from a pie slice to a slice label

Text

OPI_LBL_VALUE

Value Label associated with a slice in a pie chart

Text

OPI_LBLFEELER

Text Label associated with slice in a pie chart

Text

OPI_LBLPIE

Text associated with a pie

Text

OPI_LBLRING

Text drawn in the center of a ring pie

Area

OPI_SLICE

An individual slice in a pie (i.e., a quantitative data representation)

Area

OPI_SLICECRUST

The outer edge of a pie slice

Area

OPI_SLICEFACE

The top/face of a pie slice

Area

OPI_SLICERING

The inside edge of a pie slice

Area

OPL_CIRCLEPOLARAXIS

Circle polar axis

Text

OPL_LBLPOLARAXIS

Polar Axis Label

Line

OPL_LINES

Polar Lines

Line

OPL_THICKPOLARAXIS

Polar Axis Thick

Area

OSG_LEGEND_AREA

Legend Area

Line

OSG_LEGEND_LINE

Legend Line

Area

OSG_LEGEND_MARKER

Legend Marker

Text

OSG_LEGEND_TEXT

Legend Text

Area

OSM_RISER

Riser in a Stock Market chart

Area

OSP_SCALE_MARKER

Scale Marker in a Spectral Map

Line

OTC_COLDIVISORS

Lines separating full chart columns

Area

OTC_COLHEADAREA

Surface beneath the column headers of a table chart

Area

OTC_COLMARKER

Table Chart column marker

Area

OTC_DATAAREA

Surface beneath the data text of a table chart

Text

OTC_LBLCELL

Data text of a table chart

Text

OTC_LBLCOLHEAD

Column header text of a table chart

Text

OTC_LBLROWHEAD

Row header text of a table chart

Text

OTC_LBLROWTITLE

Row title text associated with row headers

Line

OTC_ROWDIVISORS

Lines separating full chart rows

Area

OTC_ROWHEADAREA

Surface beneath the row headers of a table chart

Area

OTC_SUBJECTAREA

Surface just above the row header surface area