This class can be used to display data as a curve in the x-y plane. It supports different display styles and symbols.
Public Member Functions | |
ErrorCurve (const Glib::ustring &title="") | |
ErrorCurve (const ErrorCurve &c) | |
virtual | ~ErrorCurve () |
const ErrorCurve & | operator= (const ErrorCurve &c) |
virtual void | set_data (const double *xData, const double *yData, int size) |
virtual void | set_data (const double *xData, const double *yData, const double *xErr, const double *yErr, int size) |
virtual void | set_data (const std::vector< double > &xData, const std::vector< double > &yData) |
virtual void | set_data (const std::vector< double > &xData, const std::vector< double > &yData, const std::vector< double > &xErr, const std::vector< double > &yErr) |
virtual void | set_data (const Glib::ArrayHandle< DoublePoint > &data) |
double | dx (int i) const |
double | dy (int i) const |
virtual Glib::RefPtr< Paint > | error_paint () const |
virtual void | draw (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from=0, int to=-1) |
virtual void | set_enabled (bool b) |
virtual bool | enabled () |
virtual int | data_size () const |
double | x (int i) const |
double | y (int i) const |
virtual DoubleRect | bounding_rect () const |
double | min_x_value () const |
double | max_x_value () const |
double | min_y_value () const |
double | max_y_value () const |
virtual void | set_options (CurveOptions t) |
virtual CurveOptions | options () const |
virtual void | set_title (const Glib::ustring &title) |
virtual const Glib::ustring & | title () const |
virtual void | set_baseline (double ref) |
virtual double | baseline () const |
virtual void | set_curve_style (CurveStyleID style, CurveOptions options=CURVE_AUTO) |
virtual CurveStyleID | curve_style () const |
virtual Glib::RefPtr< Paint > | paint () const |
virtual void | set_symbol (const Glib::RefPtr< Symbol > &s) |
virtual Glib::RefPtr< Symbol > | symbol () const |
Public Attributes | |
SigC::Signal0< void > | signal_curve_changed |
Protected Member Functions | |
virtual void | init (const Glib::ustring &title) |
virtual void | copy (const Curve &c) |
virtual void | copy (const ErrorCurve &c) |
virtual void | draw_errors_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from=0, int to=-1) |
virtual void | draw_x_error_ (const Glib::RefPtr< Gdk::Drawable > &p, int x1, int y1, int x2, int y2) |
virtual void | draw_y_error_ (const Glib::RefPtr< Gdk::Drawable > &p, int x1, int y1, int x2, int y2) |
bool | have_dx_ () const |
bool | have_dy_ () const |
virtual void | draw_curve_ (const Glib::RefPtr< Gdk::Drawable > &p, int style, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_symbols_ (const Glib::RefPtr< Gdk::Drawable > &p, const Glib::RefPtr< Symbol > &, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_lines_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_sticks_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_dots_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_lsteps_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_csteps_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | draw_rsteps_ (const Glib::RefPtr< Gdk::Drawable > &p, const DoubleIntMap &xMap, const DoubleIntMap &yMap, int from, int to) |
virtual void | close_polyline_ (const DoubleIntMap &, const DoubleIntMap &, std::vector< Gdk::Point > &) const |
virtual void | curve_changed () |
virtual int | verify_range (int &i1, int &i2) |
|
Ctor.
|
|
Copy Constructor.
|
|
Destructor.
|
|
Return the value of the baseline.
|
|
Returns the bounding rectangle of the curve data. If there is no bounding rect, like for empty data the rectangle is invalid: DoubleRect.is_valid() == FALSE |
|
Complete a polygon to be a closed polygon including the area between the original polygon and the baseline.
|
|
Copy the contents of a curve into another curve.
|
|
Copy the contents of a curve into another curve.
Reimplemented from PlotMM::Curve. |
|
Notify a change of attributes. This virtual function is called when an attribute of the curve has changed. It can be redefined by derived classes. The default implementation does nothing.
|
|
Return the current style.
|
|
Return the size of the data arrays |
|
Draw an intervall of the curve.
Reimplemented from PlotMM::Curve. |
|
Draw step function.
|
|
Draw the line part (without symbols) of a curve interval.
|
|
Draw dots.
|
|
Draw error bars.
|
|
Draw lines.
|
|
Draw step function.
|
|
Draw step function.
|
|
Draw sticks.
|
|
Draw symbols.
|
|
|
|
|
|
Query if this curve is enabled for drawing.
|
|
Return a reference to the Paint the curve is drawn with |
|
Initialize data members.
Reimplemented from PlotMM::Curve. |
|
Copy Assignment.
|
|
Return the current style options.
|
|
Return a reference to the Paint the curve is drawn with |
|
Set the value of the baseline. The baseline is needed for filling the curve with a brush or the CURVE_STICKS drawing style. The default value is 0.0. The interpretation of the baseline depends on the style options. With CURVE_Y_FX, the baseline is interpreted as a horizontal line at y = baseline(), with Curve::Yfy, it is interpreted as a vertical line at x = baseline().
|
|
Set the curve's drawing style. Valid styles are:
|
|
Initialize data with an array of points (explicitly shared).
Reimplemented from PlotMM::Curve. |
|
Initialize data with x- and y-arrays (explicitly shared).
|
|
Initialize data with x- and y-arrays (explicitly shared).
Reimplemented from PlotMM::Curve. |
|
Set data by copying x- and y-values from specified memory blocks This function makes a 'deep copy' of the data.
|
|
Set data by copying x- and y-values from specified memory blocks This function makes a 'deep copy' of the data.
Reimplemented from PlotMM::Curve. |
|
Enable or disable this curve for drawing.
|
|
Specify options for the drawing style. The options can be used to modify the drawing style. Options can be or-combined. The following options are defined:
|
|
Assign a symbol.
|
|
Assign a title to a curve.
|
|
Return the current symbol.
|
|
Return the title.
|
|
Checks if a range of indices is valid and corrects it if necessary.
|
|
|
|
|
|
Signals that this curve has changed in some way or the other.
|