On Son, 2006-02-19 at 22:49 +0100, Murray Cumming wrote: > On Sun, 2006-02-19 at 21:35 +0000, Chris Vine wrote: > > gtkmm's memory management is not the same as GTK+'s. In gtkmm, generally > > you > > have to call manage() on the widget for it to be owned by its container. > > Whether that also applies to glademm I do not know. > > glademm is not libglademm. > > When using libglademm, the memory management is like so: > http://www.gtkmm.org/docs/gtkmm-2.4/docs/tutorial/html/ch20s02.html > (it does the manage() for you.) > > Possibly that's a bit inconsistent compared to doing a regular new(), > but we didn't know how libglade worked when we first created the API, > and it's not so bad.
Sorry, I was away for some days.. by the way: the link is not right (also on the website [memory management and libglademm); the chapter about derived widgets is now at http://www.gtkmm.org/docs/gtkmm-2.4/docs/tutorial/html/ch19s03.html If libglademm does the manage() for me then this would be great. What I still don't understand is why the destructor of the derived widget (managed by libglademm according to Murray) is not called when the program ends. You can try this out very easily by writing something to the console in the dtor of the dialog widget when testing the "derived" example. This doesn't seem sane to me thinking in c++. So my question is still whether I'm responsible to delete at least the top-level widget or not. Klaus _______________________________________________ gnomemm-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/gnomemm-list
