#include <qscurve.h>
Inheritance diagram for QSCurve:
Public Types | |
enum | Channels { XVector = 0, YVector = 1, DXVector = 2, DYVector = 3, LineStyles = 4, FillStyles = 5, PointStyles = 6, ArrowStyles = 7, ErrorLineStyles = 8, XLineStyles = 9, YLineStyles = 10 } |
enum | SeriesType { Lines = 0, Area, Ribbon, Bars, Vectors, Flux, Rectangles, Ellipses, LeftStairs, MiddleStairs, RightStairs, User } |
enum | FillElement { BaseFill = 0 } |
enum | LineElement { BaseLine = 0, ErrorLine = 1, XLine = 2, YLine = 3 } |
enum | PointElement { PointMark = 0 } |
Public Methods | |
QSCurve (QSAxes *parent, const char *name=0) | |
~QSCurve () | |
void | setType (int type) |
int | type () const |
void | setFixedDelta (const QSPt2f &delta) |
void | setFixedDX (double value) |
void | setFixedDY (double value) |
void | setPercentDelta (const QSPt2f &delta) |
void | setPercentDX (double value) |
void | setPercentDY (double value) |
QSPt2f | fixedDelta () const |
double | fixedDX () const |
double | fixedDY () const |
QSPt2f | percentDelta () const |
double | percentDX () const |
double | percentDY () const |
void | setZeroPoint (const QSPt2f &p) |
void | setZeroLevelX (double x) |
void | setZeroLevelY (double y) |
QSPt2f | zeroPoint () const |
double | zeroLevelX () const |
double | zeroLevelY () const |
void | setPObject (QSSegment *po) |
QSSegment * | pObject () const |
void | setArrow1 (const QSGArrow &astyle) |
void | setArrow2 (const QSGArrow &astyle) |
void | setArrow1Property (const QString &value) |
void | setArrow2Property (const QString &value) |
QSGArrow | arrow1 () const |
QSGArrow | arrow2 () const |
QString | arrow1Property () const |
QString | arrow2Property () const |
virtual QString | posInfo (QSPt2f &pos) |
virtual QSPt2f | legendItemSize (QSDrv *drv) |
virtual void | drawLegendItem (const QSPt2f &pos, QSDrv *drv) |
virtual void | loadStateFromStream (QDataStream &stream, QSObjectFactory *factory) |
virtual void | saveStateToStream (QDataStream &stream, QSObjectFactory *factory) |
virtual QString | channelVariable (int channel) const |
virtual ColumnType | columnType (int channel, int column) const |
Protected Methods | |
virtual void | dataChanged (int channel=-1) |
virtual void | allocRuntimeData () |
virtual void | freeRuntimeData () |
virtual bool | getAxisRange (QSAxis *axis, double &min, double &max) |
virtual bool | start () |
virtual bool | step () |
virtual void | end () |
Base class for parametric curves. The appearance of QSCurve can be customized by setting your own QSSegment object, see setPObject() . Data format is described in QSCurve::Channels .See also QSAxes::plotAdd() .
|
Descriptive names of data channels. See QSData::setMatrix() All channels must be column vectors with the same number of rows. Values from the same row from all matrices define a one data point. XVector contains the x coordinate, YVector contains the y coordinate, DX vector contain the dx coordinate ( used for vectors, error bars etc ), DY vector contains the dy coordinate, and other vectors contain other attributes. |
|
See QSGraphicalData::setFill() |
|
See QSGraphicalData::setLine() |
|
|
Types of the series.
|
|
Constructor. |
|
Destructor. |
|
Called from start(). Everyting which goes to start() may be put here. inits m_curr_driver, m_curr_dpi, m_csize, m_cpos fields with values taken from parent axes Reimplemented from QSPlot. |
|
Returns arrow1 |
|
Returns arrow1 property |
|
Returns arrow2 |
|
Returns arrow2 property |
|
Returns a variable name ( 'x', 'y', 'z', 'v' etc ) for use in formulas. Reimplemented from QSData. |
|
Metadata - type of the given column. It should be reimplemented in derived classes. Used to create editors in sheet Reimplemented from QSData. |
|
This function is called after data has changed by 'setMatrix' method. You should also call it by hand, when you have changed the data in any matrix. It informs derived classes to mark old max and min data values as invalid, and informs them that they should repaint themselves. Default implementation calls dataChanging( this, channel ), Reimplemented from QSData. |
|
Draw legend item at position 'pos' Reimplemented from QSPlot. |
|
This can be called by parent axes to stop drawing. Normally called after 'step()' returned false; Reimplemented from QSPlot. |
|
Returns a fixed delta value. |
|
Returns a fixed delta value. |
|
Returns a fixed delta value. |
|
Called from end().Everyting which goes to end() may be put here. Reimplemented from QSPlot. |
|
Must be reimplemented and return data range on each axis or false when no data is set. This functions is always called outside 'start()' and 'end()' ! Reimplemented from QSPlot. |
|
Returns item size Reimplemented from QSPlot. |
|
Restores all graphics atributes Reimplemented from QSPlot. |
|
Returns a delta value. |
|
Returns a delta value. |
|
Returns a delta value. |
|
Returns the plot object or NULL. |
|
Returns info or QString::null Reimplemented from QSPlot. |
|
Saves all graphics attributes Reimplemented from QSPlot. |
|
This is usable only for vectors or errorbars. |
|
Sets arrow property |
|
This is usable only for vectors or errorbars. |
|
Sets arrow property |
|
Delta acts as a DX,DY channel with fixed values. Used when drawing vectors, error-bars, rectangle-type plots. Total delta value is calculated as follows ( example for DX ): DX[i] = DXVector[i] + FixedDelta.X + PercentDelta.X*DXVector[i]/100.0; Error is assumed to be +-delta. |
|
Sets a new fixed delta value. |
|
Sets a new fixed delta value. |
|
Delta PDX[i] = PercentDelta.X*YVector[i]/100.0. Total delta value is calculated as follows ( example for DX ): DX[i] = DXVector[i] + FixedDelta.X + PercentDelta.X*DXVector[i]/100.0; |
|
Sets a percent delta |
|
Sets a percent delta |
|
Sets a new plot object. Normally there is no need to use it. Pointer is consumed and will be deleted when not needed. Remember that also 'User' plot type must be set. |
|
Sets a new plot type. See 'SeriesType' |
|
Sets zero level. |
|
Sets zero level. |
|
Sets a zero level. It is the y value from which, for example, sample lines starts. |
|
Start drawing. Called by parent axes. Time-expensive operations should be performed in little parts during 'step()' call. If returns false - 'end()' is called immediately, if returns true - 'step()' is called next. Reimplemented from QSPlot. |
|
This function will be called to make drawing until it returns false. Notice that drawing should be stopped at any time. Even if this function returns true parent axes object may decide to call end(). Reimplemented from QSPlot. |
|
Returns the plot type. |
|
Returns the zero-level. |
|
Returns the zero-level. |
|
Returns the zero-level. |