|
Krita Source Code Documentation
|
#include <WGShadeSlider.h>
Inheritance diagram for WGShadeSlider:Classes | |
| struct | Private |
Public Slots | |
| void | resetHandle () |
| void | slotSetChannelValues (const QVector4D &values) |
Signals | |
| void | sigChannelValuesChanged (const QVector4D &values) |
| void | sigInteraction (bool active) |
Public Member Functions | |
| const QImage * | background () |
| QVector4D | channelValues () const |
| void | setDisplayMode (bool slider, int numPatches=-1) |
| void | setGradient (const QVector4D &range, const QVector4D &offset) |
| void | setModel (KisVisualColorModelSP model) |
| WGShadeSlider (WGSelectorDisplayConfigSP config, QWidget *parent=nullptr, KisVisualColorModelSP model=nullptr) | |
| ~WGShadeSlider () override | |
Protected Slots | |
| void | slotDisplayConfigurationChanged () |
Protected Member Functions | |
| bool | adjustHandleValue (const QPointF &widgetPos) |
| QVector4D | calculateChannelValues (qreal sliderPos) const |
| QPointF | convertSliderValueToWidgetCoordinate (qreal value) |
| qreal | convertWidgetCoordinateToSliderValue (QPointF coordinate) |
| int | getPatch (const QPointF pos) const |
| QSize | minimumSizeHint () const override |
| void | mouseMoveEvent (QMouseEvent *event) override |
| void | mousePressEvent (QMouseEvent *event) override |
| void | mouseReleaseEvent (QMouseEvent *event) override |
| void | paintEvent (QPaintEvent *) override |
| QRectF | patchRect (int index) const |
| void | recalculateParameters () |
| QImage | renderBackground () |
| void | resizeEvent (QResizeEvent *) override |
| bool | sizeRequirementsMet () const |
| void | strokeRect (QPainter &painter, const QRectF &rect, qreal pixelSize, qreal shrinkX) |
| strokeRect | |
Private Attributes | |
| const QScopedPointer< Private > | m_d |
Definition at line 20 of file WGShadeSlider.h.
|
explicit |
Definition at line 39 of file WGShadeSlider.cpp.
References connect(), m_d, recalculateParameters(), WGSelectorDisplayConfig::sigDisplayConfigurationChanged(), and slotDisplayConfigurationChanged().
|
override |
Definition at line 50 of file WGShadeSlider.cpp.
|
protected |
Definition at line 186 of file WGShadeSlider.cpp.
References convertWidgetCoordinateToSliderValue(), getPatch(), m_d, and qFuzzyIsNull().
| const QImage * WGShadeSlider::background | ( | ) |
Definition at line 87 of file WGShadeSlider.cpp.
References m_d, and renderBackground().
|
protected |
Definition at line 241 of file WGShadeSlider.cpp.
References m_d.
| QVector4D WGShadeSlider::channelValues | ( | ) | const |
Definition at line 82 of file WGShadeSlider.cpp.
References calculateChannelValues(), and m_d.
|
protected |
Definition at line 208 of file WGShadeSlider.cpp.
|
protected |
Definition at line 223 of file WGShadeSlider.cpp.
References m_d.
|
protected |
Definition at line 268 of file WGShadeSlider.cpp.
References m_d.
|
overrideprotected |
Definition at line 96 of file WGShadeSlider.cpp.
|
overrideprotected |
Definition at line 114 of file WGShadeSlider.cpp.
References adjustHandleValue(), channelValues(), and sigChannelValuesChanged().
|
overrideprotected |
Definition at line 101 of file WGShadeSlider.cpp.
References adjustHandleValue(), channelValues(), sigChannelValuesChanged(), and sigInteraction().
|
overrideprotected |
Definition at line 126 of file WGShadeSlider.cpp.
References sigInteraction().
|
overrideprotected |
Definition at line 135 of file WGShadeSlider.cpp.
References convertSliderValueToWidgetCoordinate(), m_d, patchRect(), renderBackground(), and strokeRect().
|
protected |
Definition at line 277 of file WGShadeSlider.cpp.
References m_d.
|
protected |
Definition at line 286 of file WGShadeSlider.cpp.
References m_d, and sizeRequirementsMet().
|
protected |
Definition at line 311 of file WGShadeSlider.cpp.
References calculateChannelValues(), convertWidgetCoordinateToSliderValue(), KoColor::data(), m_d, patchRect(), KoColorSpace::pixelSize(), strokeRect(), and KoColor::toQColor().
|
slot |
|
overrideprotected |
Definition at line 162 of file WGShadeSlider.cpp.
References recalculateParameters().
| void WGShadeSlider::setDisplayMode | ( | bool | slider, |
| int | numPatches = -1 ) |
Definition at line 61 of file WGShadeSlider.cpp.
References m_d, resetHandle(), and sizeRequirementsMet().
| void WGShadeSlider::setGradient | ( | const QVector4D & | range, |
| const QVector4D & | offset ) |
Definition at line 53 of file WGShadeSlider.cpp.
References m_d, and resetHandle().
| void WGShadeSlider::setModel | ( | KisVisualColorModelSP | model | ) |
|
signal |
|
signal |
|
protected |
|
protectedslot |
Definition at line 180 of file WGShadeSlider.cpp.
References m_d.
|
slot |
Definition at line 167 of file WGShadeSlider.cpp.
References m_d, and resetHandle().
|
protected |
strokeRect
| painter | shall already be scaled so that 1 unit == 1 real Pixel |
| rect | the rectangle to stroke in (logical) widget coordinates |
| pixelSize | devicePixelRatioF() that was used to determine the real dimensions |
| shrinkX | shrinks the rect by a multiple of the line width used to stroke |
Definition at line 368 of file WGShadeSlider.cpp.
|
private |
Definition at line 72 of file WGShadeSlider.h.