#include <qsimage.h>
Inheritance diagram for QSImage:
Public Types | |
enum | Channels { XVector = 0, YVector = 1, DataRed = 2, DataIndex = 2, DataGray = 2, DataGreen = 3, DataBlue = 4, Palette = 5 } |
Public Methods | |
QSImage (QSAxes *parent, const char *name=0) | |
~QSImage () | |
void | setRawMode (bool enabled) |
bool | rawMode () const |
void | setUseGradient (bool enable) |
bool | useGradient () const |
virtual QString | posInfo (QSPt2f &pos) |
virtual bool | isClicked (const 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 ColumnType | columnType (int channel, int column) const |
virtual QString | channelVariable (int channel) 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 () |
Data format is described in QSImage::Channels . See also QSAxes::plotAdd() .
|
Descriptive names of data channels. See QSData::setMatrix(). DataRed is required, other matrices are optional. DataRed, DataIndex, DataGray are the different names for the same channel. DataRed, DataGreen, DataBlue must have the same size. XVector ( optional ) contains x coordinates of a grid, YVector ( optional ) contains y coordinates of a grid. cols(XVector) == cols(DataRed)+1, rows(YVector) == rows(DataRed)+1, both vectors must be monotone. |
|
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 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. |
|
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 info or QString::null Reimplemented from QSPlot. |
|
Returns the current state of the raw mode setting. |
|
Saves all graphics attributes Reimplemented from QSPlot. |
|
Sets the raw mode. In the raw mode the value axis has fixed range 0-255, and there is no mapping of data values to the axis. |
|
Use gradient instead of gray levels |
|
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. |
|
if using gradient |