Re: [pygtk] how to connect a TreeModel with View

2001-12-05 Thread James Henstridge
Robert Nikander wrote: > Well I don't care too much about writing my own TreeModel. Is there > another way to put a tree in the GUI short of going back to .0.6.8? > What about gtk.TreeStore? > > I tried: > > ts = gtk.TreeStore(1, gobject.TYPE_STRING) get rid of the 1. The TreeStore constru

Re: [pygtk] how to connect a TreeModel with View

2001-12-05 Thread Matt Wilson
The constructor for TreeStore is like this: treestore = gtk.TreeStore(gobject.TYPE_STRING) No need to pass in a number. Cheers, Matt On Wed, Dec 05, 2001 at 12:42:45PM -0500, Robert Nikander wrote: > Well I don't care too much about writing my own TreeModel. Is there > another way to put a

Re: [pygtk] how to connect a TreeModel with View

2001-12-05 Thread Robert Nikander
Well I don't care too much about writing my own TreeModel. Is there another way to put a tree in the GUI short of going back to .0.6.8? What about gtk.TreeStore? I tried: ts = gtk.TreeStore(1, gobject.TYPE_STRING) but any method call on it yields: (pid:7622): GLib-GObject-WARNING **: in

Re: [pygtk] how to connect a TreeModel with View

2001-12-05 Thread James Henstridge
Robert Nikander wrote: > Hi, > > I am trying to use the new TreeModel/View stuff in the latest pygtk > (1.99.5). In short, I need to know how to 'notify' the view when my > model is updated. I have copied from the example that shows a class > that subclasses gtk.GenericTreeModel and override

Re: [pygtk] how to connect a TreeModel with View

2001-12-05 Thread Matt Wilson
The python implementation of a GtkTreeModel uses tuples as the iter. Build up the path to the new node (which is also a tuple which lists the nodes to get to the updated node), and pass it as both the path and the iter. Cheers, Matt On Wed, Dec 05, 2001 at 10:14:33AM -0500, Robert Nikander wrot