[pygtk] pygtk-libglade questions

chris@dsp.sun.ac.za chris@dsp.sun.ac.za
Mon, 14 Aug 2000 12:29:31 +0200 (SAST)


Hi all,
We have started looking at pygtk-libglade as a fast way to build user
interfaces into a pattern-recognition library.
We are currently at the "Hello World" stage of understanding. :)
I have the following question: If you have a GtkButton, and you want to
connect a python function to a "clicked" signal that the button emits, how
do you go about that?
Do you declare a "def on_button_clicked():" in the main part of your
program, or do you declare a "class UI(GladeXML):" and define the
functions inside it? 
Then, how do you declare the functions inside glade when building the XML
file?

Sorry for all these questions. I have used pygtk before, and it is
extremely useful, but we cannot find any examples/docs on pytgk/libglade,
and ANY comments would be appreceated.

Thanks,
-----------------------------------------------------
Chris Venter
Digital Signal Processing, University of Stellenbosch
email:    chris@dsp.sun.ac.za
homepage: http://www.dsp.sun.ac.za/~chris

"Plastic gun.  Ingenious.  More coffee, please."
-- The Phantom comics