[PyQt] QTableWidget: sorting floating point numbers

David Boddie dboddie at trolltech.com
Thu Sep 24 18:30:09 BST 2009

On Thu Sep 24 15:54:32 BST 2009, Bernard Van Der Stichele wrote:

> I still havn't been able to figure out how to sort numbers in a
> QTableWidget. Can anyone offer any pointers?

I don't think it's possible to do this with a QTableWidget, but it's
certainly possible to apply a proxy model to a model (which could be
a generic QStandardItemModel) and show the result in a QTableView.

I've put some example code here:



More information about the PyQt mailing list