[pygtk] gobject.type_register for class hierarchy?

Paul Pogonyshev pogonyshev at gmx.net
Thu Apr 12 05:52:10 WST 2007


Skip Montanaro wrote:
> Suppose I have this sort of class relationship:
> 
>     class A(gobject.GObject):
>         def __init__(self):
>             gobject.GObject.__init__(self)
>             ...
> 
>     class B(A):
>         ...
> 
> A is abstract.  Do I need to call gobject.type_register for just A, just B
> or both?

Only for B and only if B has some do_*() methods.  As far as I know, anyway.

Paul


More information about the pygtk mailing list