Re: pack a window in a window
- From: Stephen Kennedy <stevek gnome org>
- To: Lourens van der Vliet <lvliet home nl>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: pack a window in a window
- Date: Mon, 04 Oct 2004 17:35:47 +0100
Dnia 26-09-2004, nie o godzinie 01:26 +0200, Lourens van der Vliet
I want to have a mainwindow, where the content may vary. The content can
be composed with glade. Within glade only normal windows can be
constructed. I could of coarse rip the content of the normal window and
pack this into the main window, but when the mainwindow needs another
content we need to do some booking. This could be avoided when we could
pack the entire window into the mainwindow.
Windows in gtk are toplevel objects and can't be packed into other
windows. Another poster alluded to GtkPlug and GtkSocket which can embed
windows from other processes into a gtk+ app, but I don't think this is
what you want.
It sounds like you have the right idea though. In your glade file,
create windows as usual. Then at runtime use glade_xml_new("file.glade",
"widget_inside_window"). Now you can add it to the main window or move
it into another window with gtk_widget_reparent.
Hope this helps.
Stephen.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]