Is it possible to get a Gtk::MenuToolButton in the Toolbar by using the UIManager?



Hello, I'm creating a menu and toolbar with the UIManager and everything
works fine and display well, however what I'm trying to do is to put a
Gtk::MenuToolButton as the "new" button in the toolbar to give several
options to the user from the menu that the toolbutton pops up by
clicking the arrow, unfortunately I don't know how to add a
Gtk::MenuToolButton instead of the Gtk::ToolButton that the UIManager
normally puts.

The "ui string" I use for the toolbar is this one:

"<ui>
 " <toolbar name='MyToolBar'>"
      <toolitem action='New'/>"
 " </toolbar>"
"</ui>"

The previous string displays a button that works just fine, but I'd like
to have a Gtk::MenuToolButton to display more options when the user
chooses "New file". I've been searching and haven't found any definition
I should use in the UI String for the Gtk::MenuToolButton, if there's
any.

I also tried this:

"<ui>
" <toolbar name='MyToolBar'>"
"    <menu action="NewMenu'>"
"      <toolitem action='New'/>"
"    </menu>"
" </toolbar>"
"</ui>"

That didn't work though.

Is there a way to get a Gtk::MenuToolButton in the toolbar by using the
UIManager? Or do I need to do that "by hand"?

I've been searching and reading the documentation and I haven't figured
it out yet, If you have any link or reference I'd appreciate it.

Regards.



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