16 #ifndef QGSMAPLAYERSTYLECATEGORIESMODEL_H
17 #define QGSMAPLAYERSTYLECATEGORIESMODEL_H
22 #include <QAbstractListModel>
46 void setCategories( QgsMapLayer::StyleCategories categories );
49 QgsMapLayer::StyleCategories categories()
const;
52 void setShowAllCategories(
bool showAll );
54 int rowCount(
const QModelIndex & = QModelIndex() )
const override;
55 int columnCount(
const QModelIndex & = QModelIndex() )
const override;
56 QVariant data(
const QModelIndex &index,
int role )
const override;
57 bool setData(
const QModelIndex &index,
const QVariant &value,
int role )
override;
58 Qt::ItemFlags flags(
const QModelIndex & )
const override;
62 QgsMapLayer::StyleCategories mCategories;
64 QList<QgsMapLayer::StyleCategory> mCategoryList;
66 bool mShowAllCategories =
false;
Model for layer style categories.
QgsMapLayerType
Types of layers that can be added to a map.