[Development] QSortFilterProxyModel: recursiveFilteringEnabled

László Papp lpappyt at gmail.com
Wed Sep 20 15:54:35 CEST 2023


Hi,

Would it make sense to split this property into two?

https://doc.qt.io/qt-6/qsortfilterproxymodel.html#recursiveFilteringEnabled-prop

A use case would be something like this:

https://stackoverflow.com/questions/3384005/qt-table-and-tree-view-with-the-same-model

You want to show the leaf nodes of a selected branch node of a tree view in
a table view. Or all leaf nodes from the tree in the table view as in the
above Stack Overflow question.

Currently, you need to set recursiveFilteringEnabled to true because:

> This property holds whether the filter to be applied recursively on
children

Otherwise, the leaf nodes will not be checked, or any embedded branch node.
But the problem is then this:

> and for any matching child, its parents will be visible as well.

I would not like to have the parents visible, only the leaf like in the
above Stack Overflow question.

Thoughts? Thanks.

Kind regards,
László
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20230920/4d41f941/attachment.htm>


More information about the Development mailing list