cxGeoPlotDataColorSet - use a color to set an attribute of the current dataset to be plotted
#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)
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).
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..
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 ]