QGIS/python/gui/qgscolordialog.sip
Larry Shaffer c966dbf69b [FEATURE] Update QgsColorButton to offer live color chooser updates and show transparent checkerboard background
- Add option to Options for live color chooser support (QgsColorDialog)
- Add ability to define whether QgsColorButton accepts live updates (default: true)
- Move QgsColorButton to single subclass of QPushButton
- Show different button types relative to whether button has text
- Add transparent checkerboard background for chosen colors with alpha < 255
- Fix triple-modal window issue for Mac (with regards to using native color dialog)

- Composer item frame now supports transparency
- Composer item background transparency support moved to color dialog
- Composer composition grid now supports transparency
2013-03-21 12:42:24 -06:00

30 lines
1.1 KiB
Plaintext

/** \ingroup gui
* \class QgsColorDialog
* A dialog for selecting a color
*/
class QgsColorDialog : QObject
{
%TypeHeaderCode
#include <qgscolordialog.h>
%End
public:
QgsColorDialog();
~QgsColorDialog();
/** Return a color selection from a QColorDialog, with live updating of interim selections.
* @param initialColor The initial color of the selection dialog.
* @param updateObject The receiver object of the live updating.
* @param updateSlot The receiver object's slot for live updating (e.g. "setColor( const QColor& )" ).
* @param parent Parent widget. Usually 0 is best for native system color dialogs.
* @param title The title of the QColorDialog.
* @param options ColorDialogOptions passed to QColorDialog.
* @return Selected color on accepted() or initialColor on rejected().
*/
static QColor getLiveColor( const QColor& initialColor, QObject* updateObject, const char* updateSlot,
QWidget* parent = 0,
const QString& title = "",
QColorDialog::ColorDialogOptions options = 0 );
};