Qwt User's Guide  6.1.0
 All Classes Functions Variables Typedefs Enumerations Enumerator Pages
Public Member Functions | List of all members
QwtAlphaColorMap Class Reference

QwtAlphaColorMap varies the alpha value of a color. More...

#include <qwt_color_map.h>

Inheritance diagram for QwtAlphaColorMap:
Inheritance graph
[legend]

Public Member Functions

 QwtAlphaColorMap (const QColor &=QColor(Qt::gray))
 
virtual ~QwtAlphaColorMap ()
 Destructor.
 
void setColor (const QColor &)
 
QColor color () const
 
virtual QRgb rgb (const QwtInterval &, double value) const
 Map a value of a given interval into a alpha value. More...
 
- Public Member Functions inherited from QwtColorMap
 QwtColorMap (Format=QwtColorMap::RGB)
 Constructor.
 
virtual ~QwtColorMap ()
 Destructor.
 
Format format () const
 
QColor color (const QwtInterval &, double value) const
 
virtual QVector< QRgb > colorTable (const QwtInterval &) const
 

Additional Inherited Members

- Public Types inherited from QwtColorMap
enum  Format { RGB, Indexed }
 

Detailed Description

QwtAlphaColorMap varies the alpha value of a color.

Constructor & Destructor Documentation

QwtAlphaColorMap::QwtAlphaColorMap ( const QColor &  color = QColor( Qt::gray ))

Constructor

Parameters
colorColor of the map

Member Function Documentation

QColor QwtAlphaColorMap::color ( ) const
Returns
the color
See Also
setColor()
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();

Parameters
intervalRange for all values
valueValue to map into a RGB value
Returns
RGB value, with an alpha value

Implements QwtColorMap.

void QwtAlphaColorMap::setColor ( const QColor &  color)

Set the color

Parameters
colorColor
See Also
color()