Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you have been placed in read-only mode.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
I have a Model inheriting from QAbstractTableModel and it implements
rowCount columnCount data
but I cannot make it sort by column. I am using QTableView with setSortingEnabled set to true!
What am I missing? How can I make my model sortable?
Usually you would interpose a QSortFilterProxyModel
what do you mean to interpose?
I got it! Thanks
@jdent :) "Interpose" the proxy model between the source model and the view. The QSFPM makes it easy to manage sorting, and you get filtering too for free if you want it. Use this if you want either sorting or filtering (or both).