QGIS API Documentation 3.40.0-Bratislava (b56115d8743)
|
A QgsSingleItemModel subclass which contains a single read-only item. More...
#include <qgssingleitemmodel.h>
Public Member Functions | |
QgsSingleItemModel (QObject *parent, const QList< QMap< int, QVariant > > &columnData, Qt::ItemFlags flags=Qt::NoItemFlags) | |
Constructor for a multi-column QgsSingleItemModel with the specified parent object. | |
QgsSingleItemModel (QObject *parent=nullptr, const QString &text=QString(), const QMap< int, QVariant > &data=QMap< int, QVariant >(), Qt::ItemFlags flags=Qt::NoItemFlags) | |
Constructor for QgsSingleItemModel with the specified parent object and display text. | |
int | columnCount (const QModelIndex &parent=QModelIndex()) const override |
QVariant | data (const QModelIndex &index, int role) const override |
Qt::ItemFlags | flags (const QModelIndex &index) const override |
QModelIndex | index (int row, int column, const QModelIndex &parent=QModelIndex()) const override |
QModelIndex | parent (const QModelIndex &index) const override |
int | rowCount (const QModelIndex &parent=QModelIndex()) const override |
A QgsSingleItemModel subclass which contains a single read-only item.
Definition at line 31 of file qgssingleitemmodel.h.
|
explicit |
Constructor for QgsSingleItemModel with the specified parent object and display text.
The data map specifies the data which should be returned for the specified roles, where map keys are Qt item roles.
Custom flags can also be specified for the item.
Definition at line 19 of file qgssingleitemmodel.cpp.
|
explicit |
Constructor for a multi-column QgsSingleItemModel with the specified parent object.
The columnData list specifies the data which should be returned for the specified roles for each column in the model, where each entry in the list must be a QMap of Qt item role to value.
Custom flags can also be specified for the item.
Definition at line 28 of file qgssingleitemmodel.cpp.
|
override |
Definition at line 102 of file qgssingleitemmodel.cpp.
|
override |
Definition at line 35 of file qgssingleitemmodel.cpp.
|
override |
Definition at line 63 of file qgssingleitemmodel.cpp.
|
override |
Definition at line 75 of file qgssingleitemmodel.cpp.
|
override |
Definition at line 88 of file qgssingleitemmodel.cpp.
|
override |
Definition at line 93 of file qgssingleitemmodel.cpp.