Presentation graphics displays each data series in a way that makes it discernible from other series. It does this by defining a separate “palette” for every data series in a chart. Palettes consist of entries that determine color, line style, fill pattern, and point character used to graph the series.
Presentation graphics maintains its palettes as an array of structures. The header file PGCHART.H defines the palette structures as follows:
/* Typedef for pattern bitmap */
typedef unsigned char _fillmap[8];
/* Typedef for palette entry definition */
typedef struct
{
unsigned short color;
unsigned short style;
_fillmap fill;
char plotchar;
} _paletteentry;
/* Typedef for palette definition */
typedef _paletteentry _palettetype[_PG_PALETTELEN];
Do not confuse the presentation graphics palettes with the adapter display palettes, which are register values kept by the video controller. The function _selectpalette described in Chapter 9, “Communicating with Graphics,” sets the display palette. It does not define the data series palettes used by presentation graphics.