Re: Newbie question



On Thursday, August 14, 2003, at 03:25  AM, Fred. Oger wrote:

If a destroy a container, are the widget contained also destroyed ?

absolutely.


I have a VBox containing a widget, is it possible to replace this one
with another one ?

yes, although there are other solutions that may or may not be more appropriate.

you can hide and show widgets as you like, so you could pack two sets of widgets, and only show one set at a time. this is the trick GnomeDruid uses to replace the "Next" button with a "Finish" button.

you can use a GtkNotebook.  the tabs are optional, as i recall.

you can also use $widget->reparent, $widget->remove, $widget->add, and other fun tricks.

the gtk faq has a bit of info, too.
http://gtk.org/faq/#AEN599


How can I change the items of an ItemFactory at runtime ?

are you trying to create a dynamic menu? you may have better luck creating the menus by hand.


Sorry if those questions are silly, but this is my first attempt at
writing a graphical app.

check out the gtk tutorial and gtk faq; they are for C, but gtk2-perl is very close to C.
http://gtk.org/faq/
http://gtk.org/tutorial/




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