QGIS API Documentation 3.40.0-Bratislava (b56115d8743)
|
The QgsLayerTreeProxyModel class is a proxy model for QgsLayerTreeModel, supports private layers and text filtering. More...
#include <qgslayertreeview.h>
Public Member Functions | |
QgsLayerTreeProxyModel (QgsLayerTreeModel *treeModel, QObject *parent) | |
Constructs QgsLayerTreeProxyModel with source model treeModel and a parent. | |
bool | hideValidLayers () const |
Returns if valid layers should be hidden (i.e. | |
void | setFilterText (const QString &filterText=QString()) |
Sets filter to filterText. | |
void | setHideValidLayers (bool hideValid) |
Sets whether valid layers should be hidden (i.e. | |
void | setShowPrivateLayers (bool showPrivate) |
Determines if private layers are shown. | |
bool | showPrivateLayers () const |
Returns if private layers are shown. | |
Protected Member Functions | |
bool | filterAcceptsRow (int sourceRow, const QModelIndex &sourceParent) const override |
The QgsLayerTreeProxyModel class is a proxy model for QgsLayerTreeModel, supports private layers and text filtering.
Definition at line 46 of file qgslayertreeview.h.
QgsLayerTreeProxyModel::QgsLayerTreeProxyModel | ( | QgsLayerTreeModel * | treeModel, |
QObject * | parent | ||
) |
Constructs QgsLayerTreeProxyModel with source model treeModel and a parent.
Definition at line 836 of file qgslayertreeview.cpp.
|
overrideprotected |
Definition at line 852 of file qgslayertreeview.cpp.
bool QgsLayerTreeProxyModel::hideValidLayers | ( | ) | const |
Returns if valid layers should be hidden (i.e.
only invalid layers are shown).
Definition at line 899 of file qgslayertreeview.cpp.
void QgsLayerTreeProxyModel::setFilterText | ( | const QString & | filterText = QString() | ) |
Sets filter to filterText.
Definition at line 843 of file qgslayertreeview.cpp.
void QgsLayerTreeProxyModel::setHideValidLayers | ( | bool | hideValid | ) |
Sets whether valid layers should be hidden (i.e.
only invalid layers are shown).
Definition at line 904 of file qgslayertreeview.cpp.
void QgsLayerTreeProxyModel::setShowPrivateLayers | ( | bool | showPrivate | ) |
Determines if private layers are shown.
Definition at line 890 of file qgslayertreeview.cpp.
bool QgsLayerTreeProxyModel::showPrivateLayers | ( | ) | const |
Returns if private layers are shown.
Definition at line 885 of file qgslayertreeview.cpp.