KDEUI
#include <kcolordialog.h>

Signals | |
void | colorChanged (const QColor &) |
Public Member Functions | |
KColorPatch (QWidget *parent) | |
virtual | ~KColorPatch () |
QColor | color () const |
void | setColor (const QColor &col) |
Protected Member Functions | |
virtual void | dragEnterEvent (QDragEnterEvent *) |
virtual void | dropEvent (QDropEvent *) |
virtual void | mouseMoveEvent (QMouseEvent *) |
virtual void | paintEvent (QPaintEvent *pe) |
Properties | |
QColor | color |
Detailed Description
A color displayer.
The KColorPatch widget is a (usually small) widget showing a selected color e.g. in the KColorDialog. It automatically handles drag and drop from and on the widget.

Definition at line 116 of file kcolordialog.h.
Constructor & Destructor Documentation
◆ KColorPatch()
KColorPatch::KColorPatch | ( | QWidget * | parent | ) |
Definition at line 478 of file kcolordialog.cpp.
◆ ~KColorPatch()
|
virtual |
Definition at line 485 of file kcolordialog.cpp.
Member Function Documentation
◆ color()
QColor KColorPatch::color | ( | ) | const |
Get the currently displayed color.
◆ colorChanged
|
signal |
This signal is emitted whenever the current color changes due to a drop event.
◆ dragEnterEvent()
|
protectedvirtual |
Definition at line 518 of file kcolordialog.cpp.
◆ dropEvent()
|
protectedvirtual |
Definition at line 523 of file kcolordialog.cpp.
◆ mouseMoveEvent()
|
protectedvirtual |
Definition at line 510 of file kcolordialog.cpp.
◆ paintEvent()
|
protectedvirtual |
Definition at line 502 of file kcolordialog.cpp.
◆ setColor()
void KColorPatch::setColor | ( | const QColor & | col | ) |
Set the color to display and update the display.
- Parameters
-
col color to display
Definition at line 495 of file kcolordialog.cpp.
Property Documentation
◆ color
|
readwrite |
Definition at line 119 of file kcolordialog.h.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2017 The KDE developers.
Generated on Sat May 13 2017 06:41:41 by doxygen 1.8.13 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.