Inherits QPushButton.
Public Slots | |
void | setCurrentColor (const QColor &c) |
Signals | |
void | colorPicked (QColor) |
a colour has been chosen | |
Public Member Functions | |
void | addColor (const QColor &c, const QString &n=QString::null) |
Adds a colour with a name to the list of colours to choose from. | |
void | clear () |
Clears the colour list. | |
QwwColorButton (QWidget *parent=0) | |
void | setColors (const QList< QColor > &) |
void | setStandardColors () |
Sets standard Qt colours as the list of colours to choose from. | |
~QwwColorButton () | |
Destructor. | |
Properties | |
QList< QColor > | colors [] |
list of colours known to the button. | |
QColor | currentColor [] |
Returns the currently chosen colour. |
This widget provides a push button that can be used to choose a colour from either a predefined set of colours or a custom colour using a QColorDialog.
Colours can be added to the button with addColor(), setColors() or setStandardColors().
Definition at line 23 of file qwwcolorbutton.h.
QwwColorButton::~QwwColorButton | ( | ) |
Adds a colour with a name to the list of colours to choose from.
colour | colour to add | |
name | name to associate with the colour |
Definition at line 207 of file qwwcolorbutton.cpp.
QwwColorButton::colorPicked | ( | QColor | ) | [signal] |
a colour has been chosen
This signal is emitted when a colour is picked and displayed on the button
void QwwColorButton::setCurrentColor | ( | const QColor & | c | ) | [slot] |