QComboBox subclass which allows selecting multiple items.
More...
#include <qgscheckablecombobox.h>
QComboBox subclass which allows selecting multiple items.
- Since
- QGIS 3.0
Definition at line 124 of file qgscheckablecombobox.h.
◆ QgsCheckableComboBox()
QgsCheckableComboBox::QgsCheckableComboBox |
( |
QWidget * |
parent = nullptr | ) |
|
◆ addItemWithCheckState()
void QgsCheckableComboBox::addItemWithCheckState |
( |
const QString & |
text, |
|
|
Qt::CheckState |
state, |
|
|
const QVariant & |
userData = QVariant() |
|
) |
| |
Adds an item to the combobox with the given text, check state (stored in the Qt::CheckStateRole) and containing the specified userData (stored in the Qt::UserRole).
The item is appended to the list of existing items.
- Since
- QGIS 3.16
Definition at line 138 of file qgscheckablecombobox.cpp.
◆ checkedItems()
QStringList QgsCheckableComboBox::checkedItems |
( |
| ) |
const |
◆ checkedItemsChanged
void QgsCheckableComboBox::checkedItemsChanged |
( |
const QStringList & |
items | ) |
|
|
signal |
Emitted whenever the checked items list changed.
◆ checkedItemsData()
QVariantList QgsCheckableComboBox::checkedItemsData |
( |
| ) |
const |
◆ defaultText()
QString QgsCheckableComboBox::defaultText |
( |
| ) |
const |
◆ deselectAllOptions
void QgsCheckableComboBox::deselectAllOptions |
( |
| ) |
|
|
protectedslot |
◆ eventFilter()
bool QgsCheckableComboBox::eventFilter |
( |
QObject * |
object, |
|
|
QEvent * |
event |
|
) |
| |
|
override |
◆ hidePopup()
void QgsCheckableComboBox::hidePopup |
( |
| ) |
|
|
override |
Hides the list of items in the combobox if it is currently visible and resets the internal state.
Definition at line 201 of file qgscheckablecombobox.cpp.
◆ itemCheckState()
Qt::CheckState QgsCheckableComboBox::itemCheckState |
( |
int |
index | ) |
const |
◆ model()
◆ resizeEvent()
void QgsCheckableComboBox::resizeEvent |
( |
QResizeEvent * |
event | ) |
|
|
overrideprotected |
◆ selectAllOptions
void QgsCheckableComboBox::selectAllOptions |
( |
| ) |
|
|
protectedslot |
◆ separator()
QString QgsCheckableComboBox::separator |
( |
| ) |
const |
◆ setCheckedItems
void QgsCheckableComboBox::setCheckedItems |
( |
const QStringList & |
items | ) |
|
|
slot |
◆ setDefaultText()
void QgsCheckableComboBox::setDefaultText |
( |
const QString & |
text | ) |
|
◆ setItemCheckState()
void QgsCheckableComboBox::setItemCheckState |
( |
int |
index, |
|
|
Qt::CheckState |
state |
|
) |
| |
◆ setSeparator()
void QgsCheckableComboBox::setSeparator |
( |
const QString & |
separator | ) |
|
◆ showContextMenu
void QgsCheckableComboBox::showContextMenu |
( |
QPoint |
pos | ) |
|
|
protectedslot |
◆ toggleItemCheckState()
void QgsCheckableComboBox::toggleItemCheckState |
( |
int |
index | ) |
|
◆ mModel
◆ checkedItems
QStringList QgsCheckableComboBox::checkedItems |
|
readwrite |
◆ defaultText
QString QgsCheckableComboBox::defaultText |
|
readwrite |
◆ separator
QString QgsCheckableComboBox::separator |
|
readwrite |
The documentation for this class was generated from the following files: