16#ifndef QGSSTYLEITEMSLISTWIDGET_H
17#define QGSSTYLEITEMSLISTWIDGET_H
19#include "ui_qgsstyleitemslistwidgetbase.h"
23#include <QStyledItemDelegate>
38 explicit QgsReadOnlyStyleModel(
QgsStyleModel *sourceModel, QObject *parent =
nullptr );
39 explicit QgsReadOnlyStyleModel(
QgsStyle *style, QObject *parent =
nullptr );
42 Qt::ItemFlags flags(
const QModelIndex &index )
const override;
43 QVariant data(
const QModelIndex &index,
int role )
const override;
54class QgsStyleModelDelegate :
public QStyledItemDelegate
63 QgsStyleModelDelegate( QObject *parent );
65 QSize sizeHint(
const QStyleOptionViewItem &option,
const QModelIndex &index )
const override;
66 void paint( QPainter *painter,
const QStyleOptionViewItem &option,
const QModelIndex &index )
const override;
110 void setEntityTypes(
const QList<QgsStyle::StyleEntity> &filters )
SIP_SKIP;
130 QString currentTagFilter()
const;
139 QMenu *advancedMenu();
150 void setAdvancedMenu( QMenu *menu );
159 void showAdvancedButton(
bool enabled );
166 QString currentItemName()
const;
176 void showEvent( QShowEvent *event )
override;
207 void groupsCombo_currentIndexChanged(
int index );
208 void updateModelFilters();
209 void onSelectionChanged(
const QModelIndex &index );
210 void populateGroups();
211 void openStyleManager();
216 QgsStyleModelDelegate *mDelegate =
nullptr;
217 bool mUpdatingGroups =
false;
GeometryType
The geometry types are used to group Qgis::WkbType in a coarse way.
A model which contains entities from multiple QgsStyle databases.
A QAbstractItemModel subclass for showing symbol and color ramp entities contained within a QgsStyle ...
A QSortFilterProxyModel subclass for showing filtered symbol and color ramps entries from a QgsStyle ...
StyleEntity
Enum for Entities involved in a style.