1.

How Do I Pass Data To A Signal Handler In Glade?

Answer»

In theory, you should fill in the Object column when specifying a callback to connect to the signal. In GtkBuilder mode, you may only SPECIFY objects that Glade knows about. This is sufficient for implementing such things as the encapsulation pattern demonstrated elsewhere in iit, used to provide a callback everything it NEEDS to function in, for example, a cell RENDERER callback, by passing the TreeModel as user data.

In practice, don't even try. Pygtk 2 and Glade are both too BUGGY to attempt this. MANUALLY connect any signals that need user data.

In theory, you should fill in the Object column when specifying a callback to connect to the signal. In GtkBuilder mode, you may only specify objects that Glade knows about. This is sufficient for implementing such things as the encapsulation pattern demonstrated elsewhere in iit, used to provide a callback everything it needs to function in, for example, a cell renderer callback, by passing the TreeModel as user data.

In practice, don't even try. Pygtk 2 and Glade are both too buggy to attempt this. Manually connect any signals that need user data.



Discussion

No Comment Found