Defines a curve and its display.
More...
#include <ec_plot.h>
|
| wxEcCurve (wxString formulaX=wxEmptyString, wxString formulaY=wxEmptyString, int typeofcurve=wxECT_CARTESIAN, wxColour pencolour=*wxBLUE, int boldness=2, bool usedots=false, bool userange=false, double minrange=-10.0, double maxrange=10.0, unsigned long numpoints=wxECD_RESOLUTION, wxRealPoint *data=NULL) |
|
| ~wxEcCurve () |
|
void | Validate () |
|
void | Parse (wxString def, bool isPolar=false) |
|
bool | SortCloud () |
|
Defines a curve and its display.
wxEcCurve::wxEcCurve |
( |
wxString |
formulaX = wxEmptyString , |
|
|
wxString |
formulaY = wxEmptyString , |
|
|
int |
typeofcurve = wxECT_CARTESIAN , |
|
|
wxColour |
pencolour = *wxBLUE , |
|
|
int |
boldness = 2 , |
|
|
bool |
usedots = false , |
|
|
bool |
userange = false , |
|
|
double |
minrange = -10.0 , |
|
|
double |
maxrange = 10.0 , |
|
|
unsigned long |
numpoints = wxECD_RESOLUTION , |
|
|
wxRealPoint * |
data = NULL |
|
) |
| |
|
inline |
The default constructor. The curve is by default Defined and Enabled.
wxEcCurve::~wxEcCurve |
( |
| ) |
|
|
inline |
void wxEcCurve::Parse |
( |
wxString |
def, |
|
|
bool |
isPolar = false |
|
) |
| |
Parses a formula and applies the parameters. See the HowTo to know more about.
- Parameters
-
def | The definition. |
isPolar | Indicates if the input is expected to define a wxECT_POLAR curve. |
bool wxEcCurve::SortCloud |
( |
| ) |
|
Sorts the cloud to draw it in the right order. NumPoints is used to determine how many points to sort. The sorting technique used is bubble sort.
- Returns
- true if the data has been sorted.
void wxEcCurve::Validate |
( |
| ) |
|
Validates the curve to make it useful without generating unexpected bugs. The call is only required when you define a curve from a user's input that you have not checked beforehand.
wxRealPoint* wxEcCurve::Cloud |
wxColour wxEcCurve::Colour |
The colour used for the display.
Marks if a curve should be considerated.
The Y-coordinate will be a single point. No line is used to link to the previous computed point.
If disabled, the curve won't be displayed.
wxString wxEcCurve::ExpressionX |
The expression used for wxECT_CARTESIAN, wxECT_PARAMETRIC and wxECT_POLAR.
wxString wxEcCurve::ExpressionY |
The complementary expression needed for wxECT_PARAMETRIC.
unsigned long wxEcCurve::NumPoints |
The resolution to draw parametric and polar curves, or the number of points for a point cloud.
bool wxEcCurve::RangeEnabled |
This marks the curve to be restricted to a specific domain delimited with RangeMin and RangeMax. If the type of curve is wxECT_PARAMETRIC or wxECT_POLAR, this value shall be true.
double wxEcCurve::RangeMax |
The upper limit, for X or T. To be taken into consideration, RangeEnabled must be true.
double wxEcCurve::RangeMin |
The lower limit, for X or T. To be taken into consideration, RangeEnabled must be true.
The type of curve.
- See also
- ec_defs.h (wxECT_*)
Pen's width for the curve.
The documentation for this class was generated from the following files: