7#ifndef KIS_COLOR_SELECTOR_COMPONENT_H
8#define KIS_COLOR_SELECTOR_COMPONENT_H
62 void setParam(qreal hue, qreal hsvSaturation, qreal
value, qreal hslSaturation, qreal lightness, qreal hsiSaturation, qreal intensity, qreal hsySaturation, qreal luma);
67 void paramChanged(qreal hue, qreal hsvSaturation, qreal
value, qreal hslSaturation, qreal lightness, qreal hsiSaturation, qreal intensity, qreal hsySaturation, qreal luma);
79 virtual void paint(QPainter*) = 0;
float value(const T *src, size_t ch)
virtual bool containsPointInComponentCoords(int x, int y) const
void toggleGamutMask(bool state)
const KoColorSpace * colorSpace() const
void update()
request for repaint, for instance, if the hue changes.
bool wantsGrab(int x, int y)
returns true, if this component wants to grab the mouse (normally true, if containsPoint returns true...
void setLastMousePosition(int x, int y)
virtual void mouseEvent(int x, int y)
saves the mouse position, so that a blip can be created.
void setDirty()
force subsequent redraw of the component
const KoColorSpace * m_lastColorSpace
KisColorSelector * m_parent
KoGamutMaskSP m_currentGamutMask
void setParam(qreal hue, qreal hsvSaturation, qreal value, qreal hslSaturation, qreal lightness, qreal hsiSaturation, qreal intensity, qreal hsySaturation, qreal luma)
bool isDirty() const
returns true, if ether the color space, the size or the parameters have changed since the last paint ...
KisColorSelectorConfiguration::Parameters Parameter
KisColorSelectorComponent(KisColorSelector *parent)
virtual bool allowsColorSelectionAtPoint(const QPoint &) const
virtual void setColor(const KoColor &color)
set the color, blibs etc
void setConfiguration(Parameter param, Type type)
setConfiguration can be ignored (for instance ring and triangle, as they can have only one config)
void paintEvent(QPainter *)
void updateGamutMaskPreview()
KoColor m_lastSelectedColor
virtual KoColor selectColor(int x, int y)=0
this method must be overloaded to return the color at position x/y and draw a marker on that position
void paramChanged(qreal hue, qreal hsvSaturation, qreal value, qreal hslSaturation, qreal lightness, qreal hsiSaturation, qreal intensity, qreal hsySaturation, qreal luma)
-1, if unaffected
void setGamutMask(KoGamutMaskSP gamutMask)
KisColorSelectorConfiguration::Type Type
virtual void paint(QPainter *)=0
KoColor currentColor()
return the color, that was selected by calling mouseEvent
void setGeometry(int x, int y, int width, int height)