How to reload treeview content?

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

How to reload treeview content?

Anders Andersson
Hello.

I have a gtk.TreeView with a gtk.TreeStore that I have populated with a couple of rows. This works really well, but now I want to reload the content of the tree view and I don't really understand how to do this.

So I clear the tree store and re-create all the rows. It works, but the problem with this is that the user might have expanded certain rows. They will now be reset since the tree store's content is completely recreated.

Is there a better way to reload a tree store so that it just updates the content? Most of the rows are actually the same, and the difference is often just a number here and there in one of columns. Completely recreating it seams a bit over-complicated.

Andy


_______________________________________________
pygtk mailing list   [hidden email]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/