Re: gtk2-perl / a script to help converting basic functions



Guillaume Cottenceau <gc mandrakesoft com> writes:

It seems that in gtk-perl there is pretty much code for that (in
Gtk/GtkTypes.c)... including a garbage collector handled by hand!

Actually I think I've better understood what's going on (partly
at least): we simply can't destroy a widget when Perl's DESTROY
is called on this widget, since it would break the functional
style packing (at least).

E.g. when doing:

$box->pack_start(Gtk2::Button->new("hello"))

The DESTROY function of Gtk2::Button is called.. but we can't
destroy the button widget at that time!

I've looked in gtk2-python and there seems to be a GC mechanism
as well (even if I don't understand much of the code).

I think we won't save the burden of handling memory in a more
complicated manner than currently.

Any thought?

-- 
Guillaume Cottenceau - http://people.mandrakesoft.com/~gc/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]