NAME

cxGeoPlotDataColorSet - use a color to set an attribute of the current dataset to be plotted

C SPECIFICATION

#include <cx/Geometry.h>

enum cxGeoDataSetting
{
 CX_GEO_DATA_LSTYLE,
 CX_GEO_DATA_MARKERS,
 CX_GEO_DATA_LINE_COLOR,
 CX_GEO_DATA_LINE_PATTERN,
 CX_GEO_DATA_LINE_WIDTH,
 CX_GEO_DATA_MARKER_COLOR,
 CX_GEO_DATA_FILLED,
 CX_GEO_DATA_LABEL,
 CX_GEO_DATA_FILL_COLOR,
 CX_GEO_DATA_FILL_VALUE,
};

cxErrorCode cxGeoPlotDataColorSet (cxGeoDataSetting type, float* color)

PARAMETERS

type
The attribute of the current dataset to be set.
color
An array of three floating point numbers (interpreted as RGB values) to be used to set the attribute.

FUNCTION RETURN VALUE

cxGeoPlotDataColorSet returns an error code, an enumerated integer with cx_err_none (zero) indicating success. Any other value indicates an improper input (see below), the absence of a prior call to cxGeoPlotBegin (3E), or the absence of any datasets on the plot. A description of the error can be obtained by immediately calling cxGeoPlotGetLastError (3E).

DESCRIPTION

This function sets an attribute of the current dataset using an array of three floating-point values, which are interpreted as red, green and blue values. The current dataset is the most recently added, or it may be selected with cxGeoPlotDataFocusSet (3E). Each value may be between 0.0 (no color) and 1.0 (maximum color). Meaningful results will only be obtained for those attributes that require color. These are:

CX_GEO_PLOT_LINE_COLOR

- color of line

CX_GEO_PLOT_MARKER_COLOR

- color of markers

CX_GEO_PLOT_FILL_COLOR

- color of fill

By default, all of these colors are white (1.0, 1.0, 1.0).

Attempting to set other attributes using this function will generate an error..

SEE ALSO

cxGeoPlotBegin (3E), cxGeoPlotGetLastError (3E), cxGeoPlotDataFocusSet (3E)

The source of the LineGraph module may be found at $EXPLORERHOME/src/LineGraph/linegraph.c (UNIX) and %EXPLORERHOME%\src\LineGraph\linegraph.c (NT). It illustrates the use of many of the cxGeoPlot* routines.


Last modified: Aug 04 15:08 1999
[
Documentation Home ]

© The Numerical Algorithms Group Ltd, Oxford UK. 1999