Krita Source Code Documentation
Loading...
Searching...
No Matches
KoDualColorButton Class Reference

A widget for selecting two related colors. More...

#include <KoDualColorButton.h>

+ Inheritance diagram for KoDualColorButton:

Classes

struct  ColorDialogState
 

Public Types

enum  Selection { Foreground , Background }
 

Public Slots

QColor getColorFromDisplayRenderer (KoColor c)
 getColorFromDisplayRenderer convenience function to get the right qcolor from the display renderer, including checking whether the display renderer actually exists.
 
void openBackgroundDialog ()
 
void openForegroundDialog ()
 
void setBackgroundColor (const KoColor &color)
 
void setColorSpace (const KoColorSpace *cs)
 setColorSpace set ColorSpace so we can lock the selector. Right now this'll be changed per view-change.
 
void setDisplayRenderer (const KoColorDisplayRendererInterface *displayRenderer=KoDumbColorDisplayRenderer::instance())
 
void setForegroundColor (const KoColor &color)
 
void setPopDialog (bool popDialog)
 
void slotColorDialogClosed ()
 
void slotSetBackgroundColorFromDialog (const KoColor color)
 
void slotSetForegroundColorFromDialog (const KoColor color)
 

Signals

void backgroundColorChanged (const KoColor &color)
 
void foregroundColorChanged (const KoColor &color)
 

Public Member Functions

KoColor backgroundColor () const
 
KoColor foregroundColor () const
 
void init (KoDualColorButton *q)
 
 KoDualColorButton (const KoColor &foregroundColor, const KoColor &backgroundColor, const KoColorDisplayRendererInterface *displayRenderer, QWidget *parent=0, QWidget *dialogParent=0)
 
 KoDualColorButton (const KoColor &foregroundColor, const KoColor &backgroundColor, QWidget *parent=0, QWidget *dialogParent=0)
 
bool popDialog () const
 
 Private (const KoColor &fgColor, const KoColor &bgColor, QWidget *_dialogParent, const KoColorDisplayRendererInterface *_displayRenderer)
 
QSize sizeHint () const override
 
void updateArrows ()
 
 ~KoDualColorButton () override
 

Public Attributes

QPixmap arrowBitmap
 
KoColor backgroundColor
 
std::optional< ColorDialogStatecolorDialogState
 
KisDlgInternalColorSelectorcolorSelectorDialog
 
QWidget * dialogParent
 
QPointer< const KoColorDisplayRendererInterfacedisplayRenderer
 
bool dragFlag
 
QPoint dragPosition
 
KoColor foregroundColor
 
bool miniCtlFlag
 
bool popDialog
 
QPixmap resetPixmap
 
Selection tmpSelection
 

Protected Member Functions

void changeEvent (QEvent *event) override
 
void dragEnterEvent (QDragEnterEvent *event) override
 
void dropEvent (QDropEvent *event) override
 
bool event (QEvent *event) override
 
virtual void metrics (QRect &foregroundRect, QRect &backgroundRect)
 
void mouseMoveEvent (QMouseEvent *event) override
 
void mousePressEvent (QMouseEvent *event) override
 
void mouseReleaseEvent (QMouseEvent *event) override
 
void paintEvent (QPaintEvent *event) override
 

Private Attributes

Private *const d
 
- Private Attributes inherited from Private
KisCanvas2canvas
 
int displayedFrame
 
int intendedFrame
 

Additional Inherited Members

- Private Member Functions inherited from Private
 Private (KisCanvas2 *c)
 

Detailed Description

A widget for selecting two related colors.

KoDualColorButton allows the user to select two cascaded colors (usually a foreground and background color). Other features include drag and drop from other KDE color widgets, a reset to black and white control, and a swap colors control.

When the user clicks on the foreground or background rectangle the rectangle is first sunken and the selectionChanged() signal is emitted. Further clicks will present a color dialog and Q_EMIT either the foregroundColorChanged() or backgroundColorChanged() if a new color is selected.

Note: With drag and drop when dropping a color the current selected color will be set, while when dragging a color it will use whatever color rectangle the mouse was pressed inside.

Author
Daniel M. Duley mosfe.nosp@m.t@kd.nosp@m.e.org

Definition at line 32 of file KoDualColorButton.cpp.

Member Enumeration Documentation

◆ Selection

Enumerator
Foreground 
Background 

Definition at line 47 of file KoDualColorButton.h.

Constructor & Destructor Documentation

◆ KoDualColorButton() [1/2]

KoDualColorButton::KoDualColorButton ( const KoColor & foregroundColor,
const KoColor & backgroundColor,
QWidget * parent = 0,
QWidget * dialogParent = 0 )

Constructs a new KoDualColorButton with the supplied foreground and background colors.

Parameters
parentThe parent widget of the KoDualColorButton.
dialogParentThe parent widget of the color selection dialog.

Definition at line 107 of file KoDualColorButton.cpp.

108 : QWidget( parent ),
112{
113 d->init(this);
114}
static KoColorDisplayRendererInterface * instance()

References d.

◆ KoDualColorButton() [2/2]

KoDualColorButton::KoDualColorButton ( const KoColor & foregroundColor,
const KoColor & backgroundColor,
const KoColorDisplayRendererInterface * displayRenderer,
QWidget * parent = 0,
QWidget * dialogParent = 0 )

Definition at line 116 of file KoDualColorButton.cpp.

119 : QWidget( parent ),
123{
124 d->init(this);
125}
QPointer< const KoColorDisplayRendererInterface > displayRenderer

References d.

◆ ~KoDualColorButton()

KoDualColorButton::~KoDualColorButton ( )
override

Destroys the KoDualColorButton.

Definition at line 127 of file KoDualColorButton.cpp.

128{
129 delete d;
130}

References d.

Member Function Documentation

◆ backgroundColor()

KoColor KoDualColorButton::backgroundColor ( ) const

Returns the current background color.

◆ backgroundColorChanged

void KoDualColorButton::backgroundColorChanged ( const KoColor & color)
signal

Emitted when the background color is changed.

◆ changeEvent()

void KoDualColorButton::changeEvent ( QEvent * event)
overrideprotected

Definition at line 441 of file KoDualColorButton.cpp.

442{
443 QWidget::changeEvent(event);
444
445 switch (event->type()) {
446 case QEvent::StyleChange:
447 case QEvent::PaletteChange:
448 d->updateArrows();
449 default:
450 break;
451 }
452}
bool event(QEvent *event) override

References d, and event().

◆ dragEnterEvent()

void KoDualColorButton::dragEnterEvent ( QDragEnterEvent * event)
overrideprotected

Definition at line 250 of file KoDualColorButton.cpp.

251{
252 event->setAccepted( isEnabled() && KColorMimeData::canDecode( event->mimeData() ) );
253}

References event().

◆ dropEvent()

void KoDualColorButton::dropEvent ( QDropEvent * event)
overrideprotected

Definition at line 255 of file KoDualColorButton.cpp.

256{
257 Q_UNUSED(event);
258 /* QColor color = KColorMimeData::fromMimeData( event->mimeData() );
259
260 if ( color.isValid() ) {
261 if ( d->selection == Foreground ) {
262 d->foregroundColor = color;
263 Q_EMIT foregroundColorChanged( color );
264 } else {
265 d->backgroundColor = color;
266 Q_EMIT backgroundColorChanged( color );
267 }
268
269 update();
270 }
271*/
272}

References event().

◆ event()

bool KoDualColorButton::event ( QEvent * event)
overrideprotected

Definition at line 454 of file KoDualColorButton.cpp.

455{
456 if (event->type() == QEvent::ToolTip) {
457 QRect foregroundRect;
458 QRect backgroundRect;
459 metrics( foregroundRect, backgroundRect );
460
461 const QHelpEvent *helpEvent = static_cast<QHelpEvent*>(event);
462
463 if (this->mapFromGlobal(helpEvent->globalPos()).x() < backgroundRect.x() ) {
464 if (this->mapFromGlobal(helpEvent->globalPos()).y() < backgroundRect.y()){
465 this->setToolTip(i18n("Foreground color selector"));
466 }
467 else{
468 this->setToolTip(i18n("Set foreground and background colors to black and white"));
469 }
470 }
471 else {
472 if (this->mapFromGlobal(helpEvent->globalPos()).y() < backgroundRect.y() ) {
473 this->setToolTip(i18n("Swap foreground and background colors"));
474 }
475 else{
476 this->setToolTip(i18n("Background color selector"));
477 }
478 }
479 }
480 return QWidget::event(event);
481
482}
virtual void metrics(QRect &foregroundRect, QRect &backgroundRect)

References event(), and metrics().

◆ foregroundColor()

KoColor KoDualColorButton::foregroundColor ( ) const

Returns the current foreground color.

◆ foregroundColorChanged

void KoDualColorButton::foregroundColorChanged ( const KoColor & color)
signal

Emitted when the foreground color is changed.

◆ getColorFromDisplayRenderer

QColor KoDualColorButton::getColorFromDisplayRenderer ( KoColor c)
slot

getColorFromDisplayRenderer convenience function to get the right qcolor from the display renderer, including checking whether the display renderer actually exists.

Parameters
cthe kocolor to convert.
Returns
the qcolor to use for display.

Definition at line 202 of file KoDualColorButton.cpp.

203{
204 QColor col;
205 if (d->displayRenderer) {
206 c.convertTo(d->displayRenderer->getPaintingColorSpace());
207 col = d->displayRenderer->toQColor(c);
208 } else {
209 col = c.toQColor();
210 }
211 return col;
212}
void convertTo(const KoColorSpace *cs, KoColorConversionTransformation::Intent renderingIntent, KoColorConversionTransformation::ConversionFlags conversionFlags)
Definition KoColor.cpp:136
void toQColor(QColor *c) const
a convenience method for the above.
Definition KoColor.cpp:198

References KoColor::convertTo(), d, and KoColor::toQColor().

◆ init()

void KoDualColorButton::init ( KoDualColorButton * q)

◆ metrics()

void KoDualColorButton::metrics ( QRect & foregroundRect,
QRect & backgroundRect )
protectedvirtual

Sets the supplied rectangles to the proper size and position for the current widget size. You can reimplement this to change the layout of the widget. Restrictions are that the swap control will always be at the top right, the reset control will always be at the bottom left, and you must leave at least a 14x14 space in those corners.

Definition at line 219 of file KoDualColorButton.cpp.

220{
221 foregroundRect = QRect( 0, 0, width() - 14, height() - 14 );
222 backgroundRect = QRect( 14, 14, width() - 14, height() - 14 );
223}

◆ mouseMoveEvent()

void KoDualColorButton::mouseMoveEvent ( QMouseEvent * event)
overrideprotected

Definition at line 364 of file KoDualColorButton.cpp.

365{
366 if ( !d->miniCtlFlag ) {
367 int delay = QApplication::startDragDistance();
368
369 if ( event->x() >= d->dragPosition.x() + delay || event->x() <= d->dragPosition.x() - delay ||
370 event->y() >= d->dragPosition.y() + delay || event->y() <= d->dragPosition.y() - delay ) {
371 KColorMimeData::createDrag( d->tmpSelection == Foreground ?
372 getColorFromDisplayRenderer(d->foregroundColor) :
374 this )->exec();
375 d->dragFlag = true;
376 }
377 }
378}
QColor getColorFromDisplayRenderer(KoColor c)
getColorFromDisplayRenderer convenience function to get the right qcolor from the display renderer,...

References d, event(), Foreground, and getColorFromDisplayRenderer().

◆ mousePressEvent()

void KoDualColorButton::mousePressEvent ( QMouseEvent * event)
overrideprotected

Definition at line 319 of file KoDualColorButton.cpp.

320{
321 QRect foregroundRect;
322 QRect backgroundRect;
323
324 metrics( foregroundRect, backgroundRect );
325
326 d->dragPosition = event->pos();
327
328 d->dragFlag = false;
329
330 if ( foregroundRect.contains( d->dragPosition ) ) {
331 d->tmpSelection = Foreground;
332 d->miniCtlFlag = false;
333 }
334 else if( backgroundRect.contains( d->dragPosition ) ) {
335 d->tmpSelection = Background;
336 d->miniCtlFlag = false;
337 }
338 else if ( event->pos().x() > foregroundRect.width() ) {
339 // We handle the swap and reset controls as soon as the mouse is
340 // is pressed and ignore further events on this click (mosfet).
341
342 KoColor tmp = d->foregroundColor;
343 d->foregroundColor = d->backgroundColor;
344 d->backgroundColor = tmp;
345
346 Q_EMIT backgroundColorChanged( d->backgroundColor );
347 Q_EMIT foregroundColorChanged( d->foregroundColor );
348
349 d->miniCtlFlag = true;
350 }
351 else if ( event->pos().x() < backgroundRect.x() ) {
352 d->foregroundColor = d->displayRenderer->approximateFromRenderedQColor(Qt::black);
353 d->backgroundColor = d->displayRenderer->approximateFromRenderedQColor(Qt::white);
354
355 Q_EMIT backgroundColorChanged( d->backgroundColor );
356 Q_EMIT foregroundColorChanged( d->foregroundColor );
357
358 d->miniCtlFlag = true;
359 }
360 update();
361}
void foregroundColorChanged(const KoColor &color)
void backgroundColorChanged(const KoColor &color)
bool update(QSpinBox *spinBox)

References Background, backgroundColorChanged(), d, event(), Foreground, foregroundColorChanged(), and metrics().

◆ mouseReleaseEvent()

void KoDualColorButton::mouseReleaseEvent ( QMouseEvent * event)
overrideprotected

Definition at line 380 of file KoDualColorButton.cpp.

381{
382 d->dragFlag = false;
383
384 if ( d->miniCtlFlag )
385 return;
386
387 d->miniCtlFlag = false;
388
389 QRect foregroundRect;
390 QRect backgroundRect;
391 metrics( foregroundRect, backgroundRect );
392
393 KConfigGroup cfg = KSharedConfig::openConfig()->group("colorselector");
394 bool usePlatformDialog = cfg.readEntry("UsePlatformColorDialog", false);
395
396 if (foregroundRect.contains( event->pos())) {
397 if (d->tmpSelection == Foreground) {
398 if (d->popDialog) {
399 if (usePlatformDialog) {
400 QColor c = d->foregroundColor.toQColor();
401 c = QColorDialog::getColor(c, this);
402 if (c.isValid()) {
403 d->foregroundColor = d->displayRenderer->approximateFromRenderedQColor(c);
404 Q_EMIT foregroundColorChanged(d->foregroundColor);
405 }
406 }
407 else {
409 }
410 }
411 }
412 else {
413 d->foregroundColor = d->backgroundColor;
414 Q_EMIT foregroundColorChanged( d->foregroundColor );
415 }
416 }
417 else if (backgroundRect.contains( event->pos())) {
418 if(d->tmpSelection == Background ) {
419 if( d->popDialog) {
420 if (usePlatformDialog) {
421 QColor c = d->backgroundColor.toQColor();
422 c = QColorDialog::getColor(c, this);
423 if (c.isValid()) {
424 d->backgroundColor = d->displayRenderer->approximateFromRenderedQColor(c);
425 Q_EMIT backgroundColorChanged(d->backgroundColor);
426 }
427 }
428 else {
430 }
431 }
432 } else {
433 d->backgroundColor = d->foregroundColor;
434 Q_EMIT backgroundColorChanged( d->backgroundColor );
435 }
436 }
437
438 update();
439}

References Background, backgroundColorChanged(), d, event(), Foreground, foregroundColorChanged(), metrics(), openBackgroundDialog(), and openForegroundDialog().

◆ openBackgroundDialog

void KoDualColorButton::openBackgroundDialog ( )
slot

Definition at line 306 of file KoDualColorButton.cpp.

307{
308 d->colorDialogState.emplace();
309 d->colorDialogState->selection = Background;
310 // TODO: fix cyclic connections in a proper way
311 d->colorDialogState->connections.addUniqueConnection(d->colorSelectorDialog, SIGNAL(signalForegroundColorChosen(KoColor)), this, SLOT(slotSetBackgroundColorFromDialog(KoColor)));
312 d->colorDialogState->connections.addUniqueConnection(this, SIGNAL(backgroundColorChanged(KoColor)), d->colorSelectorDialog, SLOT(slotColorUpdated(KoColor)));
313 d->colorSelectorDialog->slotColorUpdated(d->backgroundColor);
314 d->colorSelectorDialog->setPreviousColor(d->backgroundColor);
315 d->colorSelectorDialog->show();
316 update();
317}
void slotSetBackgroundColorFromDialog(const KoColor color)

References Background, backgroundColorChanged(), d, and slotSetBackgroundColorFromDialog().

◆ openForegroundDialog

void KoDualColorButton::openForegroundDialog ( )
slot

Definition at line 293 of file KoDualColorButton.cpp.

294{
295 d->colorDialogState.emplace();
296 d->colorDialogState->selection = Foreground;
297 // TODO: fix cyclic connections in a proper way
298 d->colorDialogState->connections.addUniqueConnection(d->colorSelectorDialog, SIGNAL(signalForegroundColorChosen(KoColor)), this, SLOT(slotSetForegroundColorFromDialog(KoColor)));
299 d->colorDialogState->connections.addUniqueConnection(this, SIGNAL(foregroundColorChanged(KoColor)), d->colorSelectorDialog, SLOT(slotColorUpdated(KoColor)));
300 d->colorSelectorDialog->slotColorUpdated(d->foregroundColor);
301 d->colorSelectorDialog->setPreviousColor(d->foregroundColor);
302 d->colorSelectorDialog->show();
303 update();
304}
void slotSetForegroundColorFromDialog(const KoColor color)

References d, Foreground, foregroundColorChanged(), and slotSetForegroundColorFromDialog().

◆ paintEvent()

void KoDualColorButton::paintEvent ( QPaintEvent * event)
overrideprotected

Definition at line 225 of file KoDualColorButton.cpp.

226{
227 QRect foregroundRect;
228 QRect backgroundRect;
229
230 QPainter painter( this );
231
232 metrics( foregroundRect, backgroundRect );
233
234 QBrush defBrush = palette().brush( QPalette::Button );
235 QBrush foregroundBrush( getColorFromDisplayRenderer(d->foregroundColor), Qt::SolidPattern );
236 QBrush backgroundBrush( getColorFromDisplayRenderer(d->backgroundColor), Qt::SolidPattern );
237
238 qDrawShadeRect( &painter, backgroundRect, palette(), false, 1, 0,
239 isEnabled() ? &backgroundBrush : &defBrush );
240
241 qDrawShadeRect( &painter, foregroundRect, palette(), false, 1, 0,
242 isEnabled() ? &foregroundBrush : &defBrush );
243
244 painter.setPen( palette().color( QPalette::Shadow ) );
245
246 painter.drawPixmap( foregroundRect.right() + 2, 1, d->arrowBitmap );
247 painter.drawPixmap( 1, foregroundRect.bottom() + 2, d->resetPixmap );
248}
rgba palette[MAX_PALETTE]
Definition palette.c:35

References d, getColorFromDisplayRenderer(), metrics(), and palette.

◆ popDialog()

bool KoDualColorButton::popDialog ( ) const

Returns if a dialog with a color chooser will be popped up when clicking If false then you could/should connect to the pleasePopDialog signal and pop your own dialog. Just set the current color afterwards.

◆ Private()

KoDualColorButton::Private ( const KoColor & fgColor,
const KoColor & bgColor,
QWidget * _dialogParent,
const KoColorDisplayRendererInterface * _displayRenderer )
inline

Definition at line 35 of file KoDualColorButton.cpp.

38 : dialogParent(_dialogParent)
39 , dragFlag( false )
40 , miniCtlFlag( false )
41 , foregroundColor(fgColor)
42 , backgroundColor(bgColor)
43
44 , displayRenderer(_displayRenderer)
45 {
47 resetPixmap = QPixmap( (const char **)dcolorreset_xpm );
48
49 popDialog = true;
50 }

◆ setBackgroundColor

void KoDualColorButton::setBackgroundColor ( const KoColor & color)
slot

Sets the background color.

The internal color selector might Q_EMIT the color of a different profile, so we should break this cycling dependency somehow.

Definition at line 166 of file KoDualColorButton.cpp.

167{
168 d->backgroundColor = color;
169
170 if (d->colorDialogState && d->colorDialogState->selection == Background) {
175 KisSignalsBlocker b(d->colorSelectorDialog);
176 d->colorSelectorDialog->slotColorUpdated(color);
177 }
178
179 update();
180}

References Background, and d.

◆ setColorSpace

void KoDualColorButton::setColorSpace ( const KoColorSpace * cs)
slot

setColorSpace set ColorSpace so we can lock the selector. Right now this'll be changed per view-change.

Parameters
cs

Definition at line 197 of file KoDualColorButton.cpp.

198{
199 d->colorSelectorDialog->lockUsedColorSpace(cs);
200}

References d.

◆ setDisplayRenderer

void KoDualColorButton::setDisplayRenderer ( const KoColorDisplayRendererInterface * displayRenderer = KoDumbColorDisplayRenderer::instance())
slot

Definition at line 182 of file KoDualColorButton.cpp.

183{
184 if (d->displayRenderer && d->displayRenderer != KoDumbColorDisplayRenderer::instance()) {
185 d->displayRenderer->disconnect(this);
186 }
187 if (displayRenderer) {
188 d->displayRenderer = displayRenderer;
189 d->colorSelectorDialog->setDisplayRenderer(displayRenderer);
190 connect(d->displayRenderer, SIGNAL(destroyed()), this, SLOT(setDisplayRenderer()), Qt::UniqueConnection);
191 connect(d->displayRenderer, SIGNAL(displayConfigurationChanged()), this, SLOT(update()));
192 } else {
193 d->displayRenderer = KoDumbColorDisplayRenderer::instance();
194 }
195}
void setDisplayRenderer(const KoColorDisplayRendererInterface *displayRenderer=KoDumbColorDisplayRenderer::instance())

References d, displayRenderer, KoDumbColorDisplayRenderer::instance(), and setDisplayRenderer().

◆ setForegroundColor

void KoDualColorButton::setForegroundColor ( const KoColor & color)
slot

Sets the foreground color.

The internal color selector might Q_EMIT the color of a different profile, so we should break this cycling dependency somehow.

Definition at line 152 of file KoDualColorButton.cpp.

153{
154 d->foregroundColor = color;
155 if (d->colorDialogState && d->colorDialogState->selection == Foreground) {
160 KisSignalsBlocker b(d->colorSelectorDialog);
161 d->colorSelectorDialog->slotColorUpdated(color);
162 }
163 update();
164}

References d, and Foreground.

◆ setPopDialog

void KoDualColorButton::setPopDialog ( bool popDialog)
slot

Sets if a dialog with a color chooser should be popped up when clicking If you set this to false then you could connect to the pleasePopDialog signal and pop your own dialog. Just set the current color afterwards.

Definition at line 214 of file KoDualColorButton.cpp.

215{
216 d->popDialog = popDialog;
217}

References d, and popDialog.

◆ sizeHint()

QSize KoDualColorButton::sizeHint ( ) const
override

Returns the minimum size needed to display the widget and all its controls.

Definition at line 147 of file KoDualColorButton.cpp.

148{
149 return QSize(34, 34);
150}

◆ slotColorDialogClosed

void KoDualColorButton::slotColorDialogClosed ( )
slot

Definition at line 288 of file KoDualColorButton.cpp.

289{
290 d->colorDialogState = std::nullopt;
291}

References d.

◆ slotSetBackgroundColorFromDialog

void KoDualColorButton::slotSetBackgroundColorFromDialog ( const KoColor color)
slot

Definition at line 281 of file KoDualColorButton.cpp.

282{
283 d->backgroundColor = color;
284 update();
285 Q_EMIT backgroundColorChanged(d->backgroundColor);
286}

References backgroundColorChanged(), and d.

◆ slotSetForegroundColorFromDialog

void KoDualColorButton::slotSetForegroundColorFromDialog ( const KoColor color)
slot

Definition at line 274 of file KoDualColorButton.cpp.

275{
276 d->foregroundColor = color;
277 update();
278 Q_EMIT foregroundColorChanged(d->foregroundColor);
279}

References d, and foregroundColorChanged().

◆ updateArrows()

void KoDualColorButton::updateArrows ( )
inline

Definition at line 52 of file KoDualColorButton.cpp.

52 {
53 arrowBitmap = QPixmap(12,12);
54 arrowBitmap.fill(Qt::transparent);
55
56 QPainter p(&arrowBitmap);
57 p.setPen(dialogParent->palette().windowText().color());
58
59 // arrow pointing left
60 p.drawLine(0, 3, 7, 3);
61 p.drawLine(1, 2, 1, 4);
62 p.drawLine(2, 1, 2, 5);
63 p.drawLine(3, 0, 3, 6);
64
65 // arrow pointing down
66 p.drawLine(8, 4, 8, 11);
67 p.drawLine(5, 8, 11, 8);
68 p.drawLine(6, 9, 10, 9);
69 p.drawLine(7, 10, 9, 10);
70 }
const Params2D p

References p.

Member Data Documentation

◆ arrowBitmap

QPixmap KoDualColorButton::arrowBitmap

Definition at line 74 of file KoDualColorButton.cpp.

◆ backgroundColor

KoColor KoDualColorButton::backgroundColor
readwrite

Definition at line 78 of file KoDualColorButton.cpp.

◆ colorDialogState

std::optional<ColorDialogState> KoDualColorButton::colorDialogState

Definition at line 84 of file KoDualColorButton.cpp.

◆ colorSelectorDialog

KisDlgInternalColorSelector* KoDualColorButton::colorSelectorDialog

Definition at line 79 of file KoDualColorButton.cpp.

◆ d

Private* const KoDualColorButton::d
private

Definition at line 169 of file KoDualColorButton.h.

◆ dialogParent

QWidget* KoDualColorButton::dialogParent

Definition at line 72 of file KoDualColorButton.cpp.

◆ displayRenderer

QPointer<const KoColorDisplayRendererInterface> KoDualColorButton::displayRenderer

Definition at line 89 of file KoDualColorButton.cpp.

◆ dragFlag

bool KoDualColorButton::dragFlag

Definition at line 76 of file KoDualColorButton.cpp.

◆ dragPosition

QPoint KoDualColorButton::dragPosition

Definition at line 86 of file KoDualColorButton.cpp.

◆ foregroundColor

KoColor KoDualColorButton::foregroundColor
readwrite

Definition at line 77 of file KoDualColorButton.cpp.

◆ miniCtlFlag

bool KoDualColorButton::miniCtlFlag

Definition at line 76 of file KoDualColorButton.cpp.

◆ popDialog

bool KoDualColorButton::popDialog
readwrite

Definition at line 88 of file KoDualColorButton.cpp.

◆ resetPixmap

QPixmap KoDualColorButton::resetPixmap

Definition at line 75 of file KoDualColorButton.cpp.

◆ tmpSelection

Selection KoDualColorButton::tmpSelection

Definition at line 87 of file KoDualColorButton.cpp.


The documentation for this class was generated from the following files: