16#ifndef QGSLAYOUTITEMSLISTVIEW_H
17#define QGSLAYOUTITEMSLISTVIEW_H
24#include <QSortFilterProxyModel>
55 QVariant
data(
const QModelIndex &index,
int role = Qt::DisplayRole )
const override;
62 bool filterAcceptsRow(
int sourceRow,
const QModelIndex &sourceParent )
const override;
95 void showContextMenu( QPoint point );
98 void updateSelection(
const QItemSelection &selected,
const QItemSelection &deselected );
107 bool mUpdatingSelection =
false;
108 bool mUpdatingFromView =
false;
A common interface for layout designer dialogs and widgets.
Base class for graphical items within a QgsLayout.
Model for the layout items list view.
QgsLayoutItem * itemFromIndex(const QModelIndex &index) const
Returns the layout item listed at the specified index.
bool filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const override
QgsLayoutItemsListViewModel(QgsLayoutModel *model, QObject *parent)
constructor
void setSelected(const QModelIndex &index)
Sets the selected index.
QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const override
QModelIndex indexForItem(QgsLayoutItem *item, const int column=0) const
Returns the model index matching the specified layout item.
void setCurrentLayout(QgsLayout *layout)
Sets the current layout.
friend class TestQgsLayoutItemListView
QgsLayoutItemsListView(QWidget *parent, QgsLayoutDesignerInterface *designer)
Constructor for QgsLayoutItemsListView.
void keyPressEvent(QKeyEvent *event) override
A model for items attached to a layout.
A graphical widget to display and interact with QgsLayouts.
Base class for layouts, which can contain items such as maps, labels, scalebars, etc.