[pygtk] Registering GTK-Widgets
René 'Necoro' Neumann
lists at necoro.eu
Sun Sep 6 05:14:22 WST 2009
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
today I had a look at my application using the "Parasite" debugger [1].
And there I noticed, that widgets I created on Python-level showed up
with the last C-Class involved. I.e. for an inheritance graph like: ...
- --> GtkTreeView --> LazyView --> SomeOtherView, where GtkTreeView is the
last one on C-Level, the SomeOtherView-widgets showed up as "GtkTreeView".
So I looked for a way to deal with this, and found the
gobject.type_register function. Using this, it worked fine :) (Even if
only a look at the sourcecode revealed that one can actually pass a name
instead of autogenerating one.)
My question now is: Is this the intended way of registering widgets? And
are there any side-effects? (Oh - and are there perhaps any other nice
benefits, instead of showing the correct name in a debugger, which is
more or less a cosmetic change?)
Regards,
René
[1] http://chipx86.github.com/gtkparasite
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkqi1K4ACgkQ4UOg/zhYFuD89gCeNDtGyeMmK54MqotP52iD1o8b
opQAnRy95o6/My35Y1R3X3BuDfg8Oq5c
=y2yw
-----END PGP SIGNATURE-----
More information about the pygtk
mailing list