Franck Pommereau wrote:
Dear PyGTK users,
I would like to be able to list the signals that an arbitrary object can
be connected to. I want to be able to find the signal name, the names of
the arguments of the corresponding callback and its return type.
For instance, with gtk.Window, I would like to get:
name="activate-default", args=("window",), return=NoneType
name="activate-focus", args=("window",), return=NoneType
name="frame-event", args=("window", "event"), return=NoneType
It's not possible to get the name of an arg to a signal callback.
...
I don't mind if I get or not the signals inherited from the parent
classes (as they can be then discovered recursively).
I know that his information can be found in the reference manual, but I
want to get it from my program...
Can I use introspection to obtain this result, and how?
The closest you can get is to use gobject.signal_list_ids() and iterate
over the returned list calling gobject.signal_query().
Otherwise, can somebody give me a reference about how to interprete the
file gtk.defs which is installed with PyGTK and seems to contain all the
information that I need?
I don't believe that there is any signal info in gtk.defs.
John
_______________________________________________
pygtk mailing list [email protected]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/