setIncremental

open fun setIncremental(incremental: Boolean)

Sets the sort model to do an incremental sort.

When incremental sorting is enabled, the GtkSortListModel will not do a complete sort immediately, but will instead queue an idle handler that incrementally sorts the items towards their correct position. This of course means that items do not instantly appear in the right place. It also means that the total sorting time is a lot slower.

When your filter blocks the UI while sorting, you might consider turning this on. Depending on your model and sorters, this may become interesting around 10,000 to 100,000 items.

By default, incremental sorting is disabled.

See method@Gtk.SortListModel.get_pending for progress information about an ongoing incremental sorting operation.

Parameters

incremental

true to sort incrementally