GNOME Bugzilla – Bug 101547
Inserting items in sorted treeview is slow
Last modified: 2004-12-22 21:47:04 UTC
I've noticed that inserting items into a sorted treeview is extremely slow. There seems to be no reliable way to temporarily disable sorting while inserting a bunch of new items except deleting the Store, populating a new one and attaching that. The speed penalty is enormous, I estimate my test application to insert at least 10 times slower on the sorted treeview. There should be a function to temporarily disable sorting, in order to insert larger amounts of items. Even better would be one that completely freezes the state - visual representation, sorting info, etc. - of the tree. Applications with big lists suffer badly, Rhythmbox is an example.
That inserting items in a sorted treemodel is slower, is a known fact, because you have to use insertion sort (which is O(n) IIRC). We can't really change anything there. So basically you are asking for a function to temporarily disable sorting. Marking as DUP of a "can't disable treemodel sorting" bug. *** This bug has been marked as a duplicate of 87556 ***