[Interest] efficient natural sorting
Shawn Rutledge
Shawn.Rutledge at qt.io
Wed Nov 14 16:14:21 CET 2018
> On 14 Nov 2018, at 03:28, Frank Rueter | OHUfx <frank at ohufx.com> wrote:
>
> Hi,
>
> I need to use the QSortFilterProxyModel to sort strings with numbers in them, i.e. perform natural sorting.
Another idea is to add a different role to your model, have data() return the original number (int or qreal or whatever) in the variant for that role, and call setSortRole() to tell QSFPM which role to use.
More information about the Interest
mailing list