Home · All Classes · Grouped Classes · Annotated · Functions

QColorButton Class Reference

The QColorButton class allows users to select a color. More...

    #include <QColorButton>

Inherits QPushButton.

Public Functions

Public Slots

Signals

Protected Functions

Additional Inherited Members


Detailed Description

The QColorButton class allows users to select a color.

The QColorButton class presents a push button with the current color displayed as the label. Clicking the button pops up a color selection grid for the user to choose from a number of pre-defined colors. A default color is displayed at the bottom of the grid.


Member Function Documentation

QColorButton::QColorButton ( QWidget * parent = 0 )

Constructs a QColorButton with the given parent.

QColorButton::QColorButton ( const QColor & color, QWidget * parent = 0 )

Constructs a QColorButton with the given parent and the default color set to color.

QColorButton::~QColorButton ()

Destroys the QColorButton.

QColor QColorButton::color () const

Returns the currently selected color.

See also setColor().

const QColor & QColorButton::defaultColor () const

Returns the default color.

See also setDefaultColor() and color().

void QColorButton::drawButtonLabel ( QPainter * painter )   [protected]

Paints the color label using painter painter.

void QColorButton::selected ( const QColor & color )   [signal]

When the selected color changes, this signal is emitted with the color parameter containing the new color.

void QColorButton::setColor ( const QColor & color )   [slot]

Sets the currently selected color.

See also color().

void QColorButton::setDefaultColor ( const QColor & color )

Sets the default color.

See also defaultColor() and setColor().


Copyright © 2008 Nokia Trademarks
Qtopia 4.3.3