[pygtk] Updating a progressbar inside a recursive function

Rafael Villar Burke pachi at rvburke.com
Tue Sep 26 06:01:23 WST 2006


listas at infinicode.org wrote:
> Hi again,
>
> First of all, thanks Felix for the tips! I didn't know about os.walk,
> which is very helpful.
>
> Now eveything is worked as expected (using the gobject.idle_add trick). My
> only problem now is that filling a treeview with 200 elements is soooo
> slow if you do it this way.
You probably want to disconnect the model from the view while updating, 
to avoid that every addition regenerates the view. You set the model 
again at the end of each bunch of updates. You can see some tricks to 
improve the performance of treeviews at the pygtk.org FAQ.

Regards,

Rafael Villar Burke


More information about the pygtk mailing list