Re: [gtk-list] Re: dynamic menus with GtkItemFactory (or without
- From: Brian Masney <masneyb seul org>
- To: gtk-list redhat com
- Subject: Re: [gtk-list] Re: dynamic menus with GtkItemFactory (or without
- Date: Thu, 18 Nov 1999 13:48:50 -0500 (EST)
Hello,
The main reason that I built a tree in memory like that was for the
CTree widget that the edit bookmarks uses. But, if you want to just create
a menu dynamically you can still use gtk_item_factory_create_item() to
create it. For example:
GtkItemFactoryEntry dummy_item;
dummy_item.path = "/Menu/Item";
/* Take a look at your gtkitemfactory.h file at the _GtkItemFactory
structure for the other fields you can fill in */
gtk_item_factory_create_item (ifactory, &dummy_item, callback_data, 1);
Brian
On Thu, 18 Nov 1999, Vadim Zeitlin wrote:
> On 18-Nov-99 Brian Masney wrote:
> > I have this working with the bookmarks menu in gftp
> > (http://gftp.seul.org/). Most of the code you'll want to look for is in
> > the bookmarks.c file. If you have any questions about the code, feel
> > free to let me know.
>
> Hello Brian,
>
> thanks for your reply!
>
> I had a look at this code and, as far as I understand, you didn't
> find a way to insert an item into the menu but instead use a tree
> ctrl to edit the items and then recreate the menu completely - or
> am I missing something?
>
> I thought about doing it, but decided that it was too inefficient...
> Is there any other way to achieve this?
>
> Thanks,
> VZ
>
> --
> To unsubscribe: mail -s unsubscribe gtk-list-request@redhat.com < /dev/null
>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]