Package: gtk

Accessor gtk:sort-list-model-pending

Lambda List

gtk:sort-list-model-pending (object)

Syntax

(gtk:sort-list-model-pending object) => pending

Arguments

object -- a gtk:sort-list-model object
pending -- an unsigned integer for the estimate of unsorted items remaning

Details

The accessor for the pending slot of the gtk:sort-list-model class gets or sets the estimate of unsorted items remaining.

The estimate is the number of items that would still need to be sorted to finish the sorting operation if this was a linear algorithm. So this number is not related to how many items are already correctly sorted.

If you want to estimate the progress, you can use code like this:
(let* ((pending (gtk:sort-list-model-pending model))
       (store (gtk:sort-list-model-model model))
       (progress (- 1.0 (/ pending
                           (max 1 (g:list-model-n-items store))))))
  ... )  
If no sort operation is ongoing, in particular when the incremental property is false, this function returns 0.
 

See also

2025-08-17