Qwt User's Guide
svn
|
#include <qwt_color_map.h>
Inherits QwtColorMap.
Public Types | |
enum | Format { RGB, Indexed } |
Public Member Functions | |
QColor | color (const QwtInterval &, double value) const |
QColor | color () const |
virtual QVector< QRgb > | colorTable (const QwtInterval &) const |
Format | format () const |
QwtAlphaColorMap (const QColor &=QColor(Qt::gray)) | |
virtual QRgb | rgb (const QwtInterval &, double value) const |
void | setColor (const QColor &) |
virtual | ~QwtAlphaColorMap () |
QwtAlphaColorMap variies the alpha value of a color.
enum QwtColorMap::Format [inherited] |
Format for color mapping
QwtAlphaColorMap::QwtAlphaColorMap | ( | const QColor & | color = QColor( Qt::gray ) | ) |
Constructor
color | Color of the map |
QwtAlphaColorMap::~QwtAlphaColorMap | ( | ) | [virtual] |
Destructor.
QColor QwtColorMap::color | ( | const QwtInterval & | interval, |
double | value | ||
) | const [inline, inherited] |
Map a value into a color
interval | Valid interval for values |
value | Value |
QColor QwtAlphaColorMap::color | ( | ) | const |
QVector< QRgb > QwtColorMap::colorTable | ( | const QwtInterval & | interval | ) | const [virtual, inherited] |
Build and return a color map of 256 colors
The color table is needed for rendering indexed images in combination with using colorIndex().
interval | Range for the values |
QwtColorMap::Format QwtColorMap::format | ( | ) | const [inline, inherited] |
QRgb QwtAlphaColorMap::rgb | ( | const QwtInterval & | interval, |
double | value | ||
) | const [virtual] |
Map a value of a given interval into a alpha value.
alpha := (value - interval.minValue()) / interval.width();
interval | Range for all values |
value | Value to map into a rgb value |
Implements QwtColorMap.
void QwtAlphaColorMap::setColor | ( | const QColor & | color | ) |