Details
-
Suggestion
-
Resolution: Duplicate
-
P2: Important
-
None
-
5.15.0
-
None
Description
As mentioned in https://doc-snapshots.qt.io/qt5-dev/qml-qtquick-controls2-horizontalheaderview.html#model-prop, If model is a QAbstractItemModel , headerData() will not be accessed. But it is better if HeaderView works with QAbstractItemModel too.
for instance, if the user has something like:
TableModel* myModel = new TableModel(); QSortFilterProxyModel* proxyModel = new QSortFilterProxyModel; proxyModel->setSourceModel(myModel); engine.rootContext()->setContextProperty("tableModel", proxyModel);
If using a ProxyModel it does no longer refer to headerData() but uses data() instead.
Attachments
Issue Links
- duplicates
-
QTBUG-88283 TableView HorizontalHeaderView stops working if used with QSortFilterProxyModel
- Closed