Re: GtkUIManager




--- John Cupitt <jcupitt gmail com> wrote:

Hi,

On Mon, 6 Dec 2004 13:19:13 -0800 (PST), Harring Figueiredo
<harringf yahoo com> wrote:
"<ui>"
"<menu action='ToolsMenu'>"
"      <menuitem action='AboutTools'/>"
"      <menu name='test'/>"
"</menu>"
".. more junk in here..."

 I get the widget by calling:
 pm = gtk_ui_manager_get_widget (ui, "/ui/ToolsMenu");
  How can I attach the plugins' menu to the Tools menu ?

The widget you get for "/ui/ToolsMenu" is not the pane you add new
items to, it's the button that the pane will drop down from. You can
get the GtkMenu which ToolsMenu displays by getting the 'test' item
and then doing gtk_widget_parent().

I expect there's a clever way to make programmable menus appear and
disappear by merging XML schema with placeholders ... but I've not
tried that.

John


  I was hoping to attach "test" as a menu and then do a menu_append on the test
widget to append the plugins' menus.

  I guess I tried that, but was not successfull. I will take a look at the docs
for gtk_widget_parent.

  It seems that placeholders don;t help in this case -- perhaps I am missing
something.

  Thanks for the help.

Harring.



                
__________________________________ 
Do you Yahoo!? 
All your favorites on one personal page ? Try My Yahoo!
http://my.yahoo.com 



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