![]() |
itom
|
Public Member Functions | |
| ItomPaletteBase (const QString &name, const char type) | |
| ItomPaletteBase (const QString &name, const char type, const QColor &invCol1, const QColor &invCol2, const QColor &invalCol, const QVector< QGradientStop > &colStops) | |
| ItomPaletteBase (const QString &name, const char type, const QColor &start, const QColor &stop) | |
| ItomPaletteBase (const ItomPaletteBase &src) | |
| QString | getName () const |
| bool | setName (const QString &name) |
| int | getNumColorStops () const |
| int | getType () const |
| double | getPosFirst () const |
| double | getPosLast () const |
| double | getPos (unsigned int color) const |
| Get the position of the n-th color-stop in the palette. | |
| bool | setInverseColorOne (const QColor &color) |
| Set the first inverse color for this color bar. | |
| QColor | getInverseColorOne () const |
| bool | setInverseColorTwo (const QColor &color) |
| Set the second inverse color for this color bar. | |
| QColor | getInverseColorTwo () const |
| bool | setInvalidColor (const QColor &color) |
| Set the invalid color for this color bar. | |
| QColor | getInvalidColor () const |
| Get the invalid color for this color bar. | |
| int | findUpper (double pos) const |
| Find the next color stop and its values within this palette. | |
| QVector< QPair< double, QColor > > | getColorStops (void) const |
| bool | setColorStops (const QVector< QPair< double, QColor > > &colorStops) |
| QColor | getColor (unsigned int index) const |
| Get the RGBA-Color of the n-th color-stop in the palette. | |
| ItomPalette | getPalette () const |
| This function returns the internal structure of the palette. | |
| bool | isWriteProtected () const |
| void | setWriteProtection () |
| void | removeWriteProtection () |
| bool | insertColorStop (double pos, const QColor &color) |
| Insert a new color stop into the palette defined by color and position. | |
| QVector< ito::uint32 > | get256Colors (bool includeAlpha=false) const |
| Transform the color stops to a 256 color vector. | |
Private Attributes | |
| ItomPalette | m_paletteData |
|
inline |
Find the next color stop and its values within this palette.
\detail The palette itself is based on a small set of color stops. Between this stops, the color is linear interpolated. This function is used to give the next valid color stop for a position to allow such an interpolation.
| pos | the position within the palette |
| QVector< ito::uint32 > ito::ItomPaletteBase::get256Colors | ( | bool | includeAlpha = false | ) | const |
Transform the color stops to a 256 color vector.
\detail Transform the color stops to a 256 color vector
| updateInverseColors | recalculate the ideals inverse color |
| QColor ito::ItomPaletteBase::getColor | ( | unsigned int | index | ) | const |
Get the RGBA-Color of the n-th color-stop in the palette.
\detail This function returns the position (double value) of the color stop defined by int color
| index | index of the color stop, whose color is returned |
| QColor ito::ItomPaletteBase::getInvalidColor | ( | ) | const |
Get the invalid color for this color bar.
\detail Each colorbar has a invalid color for inf and NaN values
| color | new color as QColor value |
| ItomPalette ito::ItomPaletteBase::getPalette | ( | ) | const |
This function returns the internal structure of the palette.
\detail This function returns the internal structure of the palette
| double ito::ItomPaletteBase::getPos | ( | unsigned int | color | ) | const |
Get the position of the n-th color-stop in the palette.
\detail This function returns the position (double value) of the color stop defined by int color
| color | index of the color to retrieve |
| bool ito::ItomPaletteBase::insertColorStop | ( | double | pos, |
| const QColor & | color ) |
Insert a new color stop into the palette defined by color and position.
\detail The palette itself is based on a small set of color stops. Between this stops, the color is linear interpolated.
| pos | the position within the palette |
| color | new color as QColor value |
| bool ito::ItomPaletteBase::setInvalidColor | ( | const QColor & | color | ) |
Set the invalid color for this color bar.
\detail Each colorbar has a invalid color for inf and NaN values
| color | new color as QColor value |
| bool ito::ItomPaletteBase::setInverseColorOne | ( | const QColor & | color | ) |
Set the first inverse color for this color bar.
\detail Each colorbar has 2 inverse colors to highlight lines, cursers ...
| color | new color as QColor value |
| bool ito::ItomPaletteBase::setInverseColorTwo | ( | const QColor & | color | ) |
Set the second inverse color for this color bar.
\detail Each colorbar has 2 inverse colors to highlight lines, cursers ...
| color | new color as QColor value |