QGIS API Documentation
2.8.2-Wien
|
Allows for filtering QgsComposerAttributeTable columns by columns which are sorted or unsorted. More...
#include <qgscomposerattributetablemodelv2.h>
Public Types | |
enum | ColumnFilterType { ShowSortedColumns, ShowUnsortedColumns } |
Public Member Functions | |
QgsComposerTableSortColumnsProxyModelV2 (QgsComposerAttributeTableV2 *composerTable, ColumnFilterType filterType, QObject *parent=0) | |
Constructor for QgsComposerTableSortColumnsProxyModel. | |
virtual | ~QgsComposerTableSortColumnsProxyModelV2 () |
int | columnCount (const QModelIndex &parent=QModelIndex()) const override |
QgsComposerTableColumn * | columnFromIndex (const QModelIndex &index) const |
Returns the QgsComposerTableColumn corresponding to an index in the proxy model. | |
QgsComposerTableColumn * | columnFromRow (int row) |
Returns the QgsComposerTableColumn corresponding to a row in the proxy model. | |
QgsComposerTableColumn * | columnFromSourceIndex (const QModelIndex &sourceIndex) const |
Returns the QgsComposerTableColumn corresponding to an index from the source QgsComposerAttributeTableColumnModel model. | |
virtual QVariant | data (const QModelIndex &index, int role) const override |
Qt::ItemFlags | flags (const QModelIndex &index) const override |
QVariant | headerData (int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const override |
bool | lessThan (const QModelIndex &left, const QModelIndex &right) const override |
void | resetFilter () |
Invalidates the current filter used by the proxy model. | |
virtual bool | setData (const QModelIndex &index, const QVariant &value, int role=Qt::EditRole) override |
Protected Member Functions | |
bool | filterAcceptsRow (int source_row, const QModelIndex &source_parent) const override |
Allows for filtering QgsComposerAttributeTable columns by columns which are sorted or unsorted.
Definition at line 128 of file qgscomposerattributetablemodelv2.h.
Controls whether the proxy model shows sorted or unsorted columns
ShowSortedColumns |
show only sorted columns |
ShowUnsortedColumns |
show only unsorted columns |
Definition at line 136 of file qgscomposerattributetablemodelv2.h.
QgsComposerTableSortColumnsProxyModelV2::QgsComposerTableSortColumnsProxyModelV2 | ( | QgsComposerAttributeTableV2 * | composerTable, |
ColumnFilterType | filterType, | ||
QObject * | parent = 0 |
||
) |
Constructor for QgsComposerTableSortColumnsProxyModel.
composerTable | QgsComposerAttributeTable the model is attached to |
filterType | filter for columns, controls whether sorted or unsorted columns are shown |
parent | optional parent |
Definition at line 422 of file qgscomposerattributetablemodelv2.cpp.
|
virtual |
Definition at line 430 of file qgscomposerattributetablemodelv2.cpp.
|
override |
Definition at line 488 of file qgscomposerattributetablemodelv2.cpp.
QgsComposerTableColumn * QgsComposerTableSortColumnsProxyModelV2::columnFromIndex | ( | const QModelIndex & | index | ) | const |
Returns the QgsComposerTableColumn corresponding to an index in the proxy model.
index | a QModelIndex |
Definition at line 458 of file qgscomposerattributetablemodelv2.cpp.
QgsComposerTableColumn * QgsComposerTableSortColumnsProxyModelV2::columnFromRow | ( | int | row | ) |
Returns the QgsComposerTableColumn corresponding to a row in the proxy model.
row | a row number |
Definition at line 607 of file qgscomposerattributetablemodelv2.cpp.
QgsComposerTableColumn * QgsComposerTableSortColumnsProxyModelV2::columnFromSourceIndex | ( | const QModelIndex & | sourceIndex | ) | const |
Returns the QgsComposerTableColumn corresponding to an index from the source QgsComposerAttributeTableColumnModel model.
sourceIndex | a QModelIndex |
Definition at line 465 of file qgscomposerattributetablemodelv2.cpp.
|
overridevirtual |
Definition at line 494 of file qgscomposerattributetablemodelv2.cpp.
|
overrideprotected |
Definition at line 435 of file qgscomposerattributetablemodelv2.cpp.
|
override |
Definition at line 568 of file qgscomposerattributetablemodelv2.cpp.
|
override |
Definition at line 534 of file qgscomposerattributetablemodelv2.cpp.
|
override |
Definition at line 473 of file qgscomposerattributetablemodelv2.cpp.
void QgsComposerTableSortColumnsProxyModelV2::resetFilter | ( | ) |
Invalidates the current filter used by the proxy model.
Definition at line 613 of file qgscomposerattributetablemodelv2.cpp.
|
overridevirtual |
Definition at line 581 of file qgscomposerattributetablemodelv2.cpp.