Qt Utilities  5.13.0
Common Qt related C++ classes and routines used by my applications such as dialogs, widgets and models
Public Slots | Signals | Public Member Functions | Protected Member Functions | Properties | List of all members
Widgets::ColorButton Class Reference

The ColorButton class is used by PaletteEditor. More...

#include <colorbutton.h>

Inheritance diagram for Widgets::ColorButton:
[legend]
Collaboration diagram for Widgets::ColorButton:
[legend]

Public Slots

void setColor (const QColor &color)
 

Signals

void colorChanged (const QColor &color)
 

Public Member Functions

 ColorButton (QWidget *parent=nullptr)
 
 ~ColorButton () override
 
bool isBackgroundCheckered () const
 
void setBackgroundCheckered (bool checkered)
 
QColor color () const
 

Protected Member Functions

void paintEvent (QPaintEvent *event) override
 
void mousePressEvent (QMouseEvent *event) override
 
void mouseMoveEvent (QMouseEvent *event) override
 
void dragEnterEvent (QDragEnterEvent *event) override
 
void dragLeaveEvent (QDragLeaveEvent *event) override
 
void dropEvent (QDropEvent *event) override
 

Properties

bool backgroundCheckered
 

Detailed Description

The ColorButton class is used by PaletteEditor.

This is taken from qttools/src/shared/qtgradienteditor/qtcolorbutton.h.

Definition at line 15 of file colorbutton.h.

Constructor & Destructor Documentation

◆ ColorButton()

Widgets::ColorButton::ColorButton ( QWidget *  parent = nullptr)

Definition at line 83 of file colorbutton.cpp.

◆ ~ColorButton()

Widgets::ColorButton::~ColorButton ( )
override

Definition at line 97 of file colorbutton.cpp.

Member Function Documentation

◆ color()

QColor Widgets::ColorButton::color ( ) const

Definition at line 109 of file colorbutton.cpp.

◆ colorChanged

void Widgets::ColorButton::colorChanged ( const QColor &  color)
signal

◆ dragEnterEvent()

void Widgets::ColorButton::dragEnterEvent ( QDragEnterEvent *  event)
overrideprotected

Definition at line 205 of file colorbutton.cpp.

◆ dragLeaveEvent()

void Widgets::ColorButton::dragLeaveEvent ( QDragLeaveEvent *  event)
overrideprotected

Definition at line 217 of file colorbutton.cpp.

◆ dropEvent()

void Widgets::ColorButton::dropEvent ( QDropEvent *  event)
overrideprotected

Definition at line 224 of file colorbutton.cpp.

◆ isBackgroundCheckered()

bool Widgets::ColorButton::isBackgroundCheckered ( ) const

Definition at line 122 of file colorbutton.cpp.

◆ mouseMoveEvent()

void Widgets::ColorButton::mouseMoveEvent ( QMouseEvent *  event)
overrideprotected

Definition at line 186 of file colorbutton.cpp.

◆ mousePressEvent()

void Widgets::ColorButton::mousePressEvent ( QMouseEvent *  event)
overrideprotected

Definition at line 177 of file colorbutton.cpp.

◆ paintEvent()

void Widgets::ColorButton::paintEvent ( QPaintEvent *  event)
overrideprotected

Definition at line 127 of file colorbutton.cpp.

◆ setBackgroundCheckered()

void Widgets::ColorButton::setBackgroundCheckered ( bool  checkered)

Definition at line 114 of file colorbutton.cpp.

◆ setColor

void Widgets::ColorButton::setColor ( const QColor &  color)
slot

Definition at line 101 of file colorbutton.cpp.

Property Documentation

◆ backgroundCheckered

bool Widgets::ColorButton::backgroundCheckered
readwrite

Definition at line 17 of file colorbutton.h.


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