Re: Moving widgets from one parent to another...?



Quoting Paul Davis <pbd Op Net>:

> by default, when you add a widget to a container, the container
> takes ownership of the widget. when you then remove it, it takes
> responsibility for deleting it.
> 
> adding a reference will stop this.
> 
> you can also use gtk_widget_reparent() to hide all this, IIRC.

OK, thanks Paul.  That's cool - the reparent thing does work.  The problem I
have now seems to be that moving vbox2 from window2 to vbox1 doesn't appear to
move all its children, unless I am wrong in guessing that gtk_widget_show_all
actually causes a widget AND ALL ITS CHILDREN to be shown?

TIA

John Breen



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