KWidgetsAddons
kcolorcombo.cpp
32 void paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const override;
57void KColorComboDelegate::paint(QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const
62 bool paletteBrush = (k_colorcombodelegate_brush(index, Qt::BackgroundRole).style() == Qt::NoBrush);
116QSize KColorComboDelegate::sizeHint(const QStyleOptionViewItem &option, const QModelIndex &index) const
289 QRect frame = style()->subControlRect(QStyle::CC_ComboBox, &opt, QStyle::SC_ComboBoxEditField, this);
void setColors(const QList< QColor > &colors)
Set a custom list of colors to choose from, in place of the standard list.
Definition kcolorcombo.cpp:235
void showEmptyList()
Clear the color list and don't show it, till the next setColor() call.
Definition kcolorcombo.cpp:296
void activated(const QColor &col)
Emitted when a new color box has been selected.
bool isCustomColor() const
Find whether the currently selected color is a custom color selected using a color dialog.
Definition kcolorcombo.cpp:274
void highlighted(const QColor &col)
Emitted when a new item has been highlighted.
QStyle * style()
Qt::BrushStyle style() const const
bool isValid() const const
QColor getColor(const QColor &initial, QWidget *parent, const QString &title, ColorDialogOptions options)
void activated(int index)
void addItem(const QIcon &icon, const QString &text, const QVariant &userData)
void clear()
count
void setCurrentIndex(int index)
virtual bool event(QEvent *event) override
frame
void highlighted(int index)
virtual void initStyleOption(QStyleOptionComboBox *option) const const
void setMaxVisibleItems(int maxItems)
void setItemData(int index, const QVariant &value, int role)
void setItemDelegate(QAbstractItemDelegate *delegate)
qsizetype count() const const
qsizetype indexOf(const AT &value, qsizetype from) const const
bool isEmpty() const const
void reserve(qsizetype size)
QBrush
QVariant data(int role) const const
Q_OBJECTQ_OBJECT
QMetaObject::Connection connect(const QObject *sender, PointerToMemberFunction signal, Functor functor)
QObject * parent() const const
QString tr(const char *sourceText, const char *disambiguation, int n)
RenderHints
void drawRoundedRect(const QRect &rect, qreal xRadius, qreal yRadius, Qt::SizeMode mode)
void drawText(const QPoint &position, const QString &text)
RenderHints renderHints() const const
void setBrush(Qt::BrushStyle style)
void setPen(Qt::PenStyle style)
void setRenderHint(RenderHint hint, bool on)
void setRenderHints(RenderHints hints, bool on)
Highlight
QRect adjusted(int dx1, int dy1, int dx2, int dy2) const const
CC_ComboBox
PE_PanelItemViewItem
State_Selected
SC_ComboBoxEditField
virtual void drawPrimitive(PrimitiveElement element, const QStyleOption *option, QPainter *painter, const QWidget *widget) const const=0
virtual QRect subControlRect(ComplexControl control, const QStyleOptionComplex *option, SubControl subControl, const QWidget *widget) const const=0
NoBrush
white
UserRole
QString toString() const const
int userType() const const
T value() const const
palette
QStyle * style() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:09:51 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Mon Nov 18 2024 12:09:51 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.