[PyQt] QSortFilterProxyModel + QTreeView sort problem/bug
Baba-k
babakage at gmail.com
Thu Mar 12 11:39:08 GMT 2009
Hi Guys,
I'm having a problem whereby the items in the QAbstractItemModel/QTreeView
collapse after a sort. Im using a custom QAbstractItemModel wrapped in a
QSortFilerProxyModel which is being displayed in a QTreeView. I've enabled
sorting in the tree view by calling setSortingEnabled(True) on it. Whenever
I click a header to sort it some of the items collapse/expand, it makes
sorting abit problematic.
It seems to work fine using pyqt 4.2 and qt 4.22 with python2.4.3, but when
using python2.5.1, pyqt 4.4.2, qt 4.4.0 I get this weird behaviour.
This problem can be recreated using the 'sortingmodel' example that comes
with pyqt. If you enable sorting on the sorted view then try to sort it
while running pyqt4.4.2 then some of the items will collapse if expanded,
where as pyqt4.2 is fine.
Has any one else experienced this problem before or know of any
solutions/workaround ?? Any help would be greatly appreciated.
thanks
babak
--
View this message in context: http://www.nabble.com/QSortFilterProxyModel-%2B-QTreeView-sort-problem-bug-tp22474293p22474293.html
Sent from the PyQt mailing list archive at Nabble.com.
More information about the PyQt
mailing list