Public Types | Public Member Functions | Private Member Functions | Private Attributes

QwtErrorPlotCurve Class Reference

Error bars curve. More...

#include <QwtErrorPlotCurve.h>

Inheritance diagram for QwtErrorPlotCurve:
DataCurve PlotCurve

List of all members.

Public Types

enum  Orientation { Horizontal = 0, Vertical = 1 }

Public Member Functions

QwtDoubleRect boundingRect () const
int capLength ()
QColor color ()
void copy (const QwtErrorPlotCurve *e)
void detachFromMasterCurve ()
 Causes the master curve to delete this curve from its managed error bars list.
int direction ()
void drawMinusSide (bool yes)
void drawPlusSide (bool yes)
void drawThroughSymbol (bool yes)
QwtArray< double > errors ()
double errorValue (int i)
void loadData ()
DataCurvemasterCurve ()
 Returns the master curve to which this error bars curve is attached.
bool minusSide ()
QString plotAssociation ()
 A list of data sources for this curve.
bool plusSide ()
 QwtErrorPlotCurve (Table *t, const QString &name)
 QwtErrorPlotCurve (int orientation, Table *t, const QString &name)
void setCapLength (int t)
void setColor (const QColor &c)
void setDirection (int o)
void setErrors (const QwtArray< double > &data)
void setMasterCurve (DataCurve *c)
void setWidth (double w)
void setXErrors (bool yes)
bool throughSymbol ()
bool updateData (Table *t, const QString &colName)
double width ()
bool xErrors ()

Private Member Functions

virtual void draw (QPainter *painter, const QwtScaleMap &xMap, const QwtScaleMap &yMap, int from, int to) const
void drawErrorBars (QPainter *painter, const QwtScaleMap &xMap, const QwtScaleMap &yMap, int from, int to) const
void init ()

Private Attributes

int d_cap_length
 Length of the bar cap decoration.
DataCurved_master_curve
 Reference to the master curve to which this error bars curve is attached.
QwtArray< double > err
 Stores the error bar values.
bool minus
bool plus
bool through
int type
 Orientation of the bars: Horizontal or Vertical.

Detailed Description

Error bars curve.


Member Enumeration Documentation

Enumerator:
Horizontal 
Vertical 

Constructor & Destructor Documentation

QwtErrorPlotCurve::QwtErrorPlotCurve ( int  orientation,
Table t,
const QString &  name 
)

References init(), and PlotCurve::type().

QwtErrorPlotCurve::QwtErrorPlotCurve ( Table t,
const QString &  name 
)

References init(), and PlotCurve::type().


Member Function Documentation

QwtDoubleRect QwtErrorPlotCurve::boundingRect (  )  const

Reimplemented from PlotCurve.

References err, PlotCurve::type(), and Vertical.

int QwtErrorPlotCurve::capLength (  )  [inline]
QColor QwtErrorPlotCurve::color (  )  [inline]
void QwtErrorPlotCurve::copy ( const QwtErrorPlotCurve e  ) 
void QwtErrorPlotCurve::detachFromMasterCurve (  )  [inline]

Causes the master curve to delete this curve from its managed error bars list.

References d_master_curve, and DataCurve::removeErrorBars().

int QwtErrorPlotCurve::direction (  )  [inline]

References type.

Referenced by Graph::saveCurves().

void QwtErrorPlotCurve::draw ( QPainter *  painter,
const QwtScaleMap &  xMap,
const QwtScaleMap &  yMap,
int  from,
int  to 
) const [private, virtual]

References drawErrorBars().

void QwtErrorPlotCurve::drawErrorBars ( QPainter *  painter,
const QwtScaleMap &  xMap,
const QwtScaleMap &  yMap,
int  from,
int  to 
) const [private]
void QwtErrorPlotCurve::drawMinusSide ( bool  yes  )  [inline]

References minus.

Referenced by Graph::addErrorBars(), and Graph::updateErrorBars().

void QwtErrorPlotCurve::drawPlusSide ( bool  yes  )  [inline]

References plus.

Referenced by Graph::addErrorBars(), and Graph::updateErrorBars().

void QwtErrorPlotCurve::drawThroughSymbol ( bool  yes  )  [inline]

References through.

Referenced by Graph::addErrorBars(), and Graph::updateErrorBars().

QwtArray<double> QwtErrorPlotCurve::errors (  )  [inline]

References err.

double QwtErrorPlotCurve::errorValue ( int  i  ) 

References err.

Referenced by Fit::setDataCurve(), and Fit::setWeightingData().

void QwtErrorPlotCurve::init (  )  [private]
DataCurve* QwtErrorPlotCurve::masterCurve (  )  [inline]
bool QwtErrorPlotCurve::minusSide (  )  [inline]
QString QwtErrorPlotCurve::plotAssociation (  )  [virtual]

A list of data sources for this curve.

Elements must be in either of the following forms:

  • <id of X column> "(X)," <id of Y column> "(Y)" [ "," <id of error column> ("(xErr)" | "(yErr)") ]
  • <id of Xstart column> "(X)," <id of Ystart column>"(Y)," <id of Xend column> "(X)," <id of Yend column> "(Y)"
    (denoting start and end coordinates for the VectXYXY style)
  • <id of Xstart column> "(X)," <id of Ystart column> "(Y)," <id of angle column> "(A)," <id of magnitude column> "(M)"
    (denoting start coordinates, angle in radians and length for the VectXYAM style)

Column ids are of the form '<name of table> "_" <name of column>'.

Reimplemented from DataCurve.

References d_master_curve, Horizontal, PlotCurve::type(), and DataCurve::xColumnName().

bool QwtErrorPlotCurve::plusSide (  )  [inline]
void QwtErrorPlotCurve::setCapLength ( int  t  )  [inline]
void QwtErrorPlotCurve::setDirection ( int  o  )  [inline]
void QwtErrorPlotCurve::setErrors ( const QwtArray< double > &  data  )  [inline]

References err.

Referenced by loadData().

void QwtErrorPlotCurve::setWidth ( double  w  ) 
void QwtErrorPlotCurve::setXErrors ( bool  yes  ) 

References PlotCurve::type().

Referenced by Graph::updateErrorBars().

bool QwtErrorPlotCurve::throughSymbol (  )  [inline]
bool QwtErrorPlotCurve::updateData ( Table t,
const QString &  colName 
) [virtual]

Reimplemented from DataCurve.

References DataCurve::d_table, and loadData().

double QwtErrorPlotCurve::width (  )  [inline]
bool QwtErrorPlotCurve::xErrors (  ) 

Member Data Documentation

Length of the bar cap decoration.

Referenced by capLength(), copy(), drawErrorBars(), and setCapLength().

Reference to the master curve to which this error bars curve is attached.

Referenced by detachFromMasterCurve(), drawErrorBars(), loadData(), masterCurve(), plotAssociation(), and setMasterCurve().

QwtArray<double> QwtErrorPlotCurve::err [private]

Stores the error bar values.

Referenced by boundingRect(), copy(), drawErrorBars(), errors(), errorValue(), loadData(), and setErrors().

int QwtErrorPlotCurve::type [private]

Orientation of the bars: Horizontal or Vertical.

Referenced by copy(), and direction().


The documentation for this class was generated from the following files: