This class contours a grid. More...
#include "../include/Contour.h"
Public Types | |
| enum | { NONE, VALUE, LINE, FILL, BOTH } |
Public Member Functions | |
| int | init () |
| int | setParam (const char *str) |
| int | setType (int rtype) |
| int | setType (const char *str) |
| int | getType () |
| bool | isTypeFill () |
| int | setInterval (float val) |
| float | getInterval () |
| int | setBase (float val) |
| float | getBase () |
| float | getMax () |
| float | getMin () |
| int | setLabelParam (int skip, int rad) |
| int | setLabelSpace (int x, int y) |
| int | setFillStyle (int type) |
| int | setLineWidth (float width) |
| int | setColorTable (const char *str) |
| int | setColorFill (const char *str) |
| int | setColorLine (const char *str) |
| int | setColorLabel (const char *str) |
| int | setScaleFactor (float sc) |
| int | draw (Plot &plot, Grid &grid) |
| int | drawLabels (Plot &plot, Grid &grid) |
| int | drawFill (Plot &plot, Grid &grid) |
| int | drawBoxFill (Plot &plot, Grid &grid) |
| int | drawLine (Plot &plot, Grid &grid) |
| int | drawBoxLine (Plot &plot, Grid &grid) |
| int | drawValues (Plot &plot, Grid &grid) |
| int | drawLineLabels (Plot &plot, Grid &grid) |
| int | drawMaxMin (Plot &plot, Grid &grid) |
| int | drawBar (Plot &plot, const char *locate) |
| float | getLevel (int ind) |
| PlotAttr | getColorFill (int ind) |
Static Public Member Functions | |
| static int | decodeType (const char *str) |
This class contours a grid.
Contours the grid
Referenced by WXP::UpaXSectCont::draw().
| int Contour::drawBar | ( | Plot & | plot, | |
| const char * | locate | |||
| ) |
Draws the color bar legend
| plot | Plot object | |
| locate | Location of bar |
| int Contour::init | ( | ) |
Initializes the object
References WXP::ColorFill::init(), WXP::String::init(), WXP::Const::MISS, setBase(), setColorFill(), setColorLine(), setColorTable(), setInterval(), and setParam().
| int Contour::setBase | ( | float | val | ) |
Sets the contour base value used in color fill and other parameters
| val | Base value |
Referenced by WXP::UpaXSectCont::draw(), init(), and setParam().
| int Contour::setColorFill | ( | const char * | str | ) |
Sets the color fill parameters
| str | Color fill string |
References WXP::String::set().
Referenced by init(), WXP::GridCont::setColorFill(), and setParam().
| int Contour::setColorLabel | ( | const char * | str | ) |
| int Contour::setColorLine | ( | const char * | str | ) |
Sets the color for line contours
| str | Color string |
References WXP::String::set().
Referenced by init(), and setParam().
| int Contour::setColorTable | ( | const char * | str | ) |
Sets the color table parameters
| str | Color table parameter |
References WXP::String::set().
Referenced by init(), WXP::GridCont::setColorTable(), and setParam().
| int Contour::setFillStyle | ( | int | type | ) |
| int Contour::setInterval | ( | float | val | ) |
Sets the contour interval
| val | Contour interval |
Referenced by WXP::UpaXSectCont::draw(), init(), and setParam().
| int Contour::setLabelParam | ( | int | skip, | |
| int | rad | |||
| ) |
Sets the label parameters
| skip | Contour value skip factor | |
| rad | Search radius for max/min labels |
Referenced by setParam().
| int Contour::setLabelSpace | ( | int | x, | |
| int | y | |||
| ) |
Sets the spacing factors for contour line labels
| x | X skip factor | |
| y | Y skip factor |
Referenced by setParam().
| int Contour::setLineWidth | ( | float | width | ) |
| int Contour::setParam | ( | const char * | str | ) |
Sets the contouring parameters
| str | Parameter string ty=type - Contour type pl=type - Contour type in=intrvl - Contour interval base=val - Contour base cb=val - Contour base fill=type - Contour fill type ct=file - Color table file coco=color - Line contour color coln=color - Line contour color cof=color - Fill contour colors lab=s:r:x:y - Label parameters: skip, rad, x, y |
References WXP::StrLib::copy(), WXP::Strings::equal(), WXP::Strings::getNum(), WXP::Strings::getString(), WXP::Strings::getStringAfter(), WXP::Strings::scanf(), setBase(), setColorFill(), setColorLine(), setColorTable(), setFillStyle(), setInterval(), setLabelParam(), setLabelSpace(), setLineWidth(), and setScaleFactor().
Referenced by WXP::UpaXSectCont::draw(), init(), and WXP::GridCont::setParam().
| int Contour::setScaleFactor | ( | float | sc | ) |
| int Contour::setType | ( | const char * | str | ) |
Sets the contour type
| str | Type of contours (cf, ln, dln, ndln, value, gvalue) |
References WXP::StrLib::equal().
1.6.1