Trait gtk::prelude::MenuToolButtonExt[][src]

pub trait MenuToolButtonExt: 'static {
    fn menu(&self) -> Option<Widget>;
fn set_arrow_tooltip_markup(&self, markup: &str);
fn set_arrow_tooltip_text(&self, text: &str);
fn set_menu<P: IsA<Widget>>(&self, menu: &P);
fn connect_show_menu<F: Fn(&Self) + 'static>(&self, f: F) -> SignalHandlerId;
fn connect_menu_notify<F: Fn(&Self) + 'static>(
        &self,
        f: F
    ) -> SignalHandlerId; }
Expand description

Trait containing all MenuToolButton methods.

Implementors

MenuToolButton

Required methods

Gets the Menu associated with MenuToolButton.

Returns

the Menu associated with MenuToolButton

Sets the tooltip markup text to be used as tooltip for the arrow button which pops up the menu. See gtk_tool_item_set_tooltip_text() for setting a tooltip on the whole MenuToolButton.

markup

markup text to be used as tooltip text for button’s arrow button

Sets the tooltip text to be used as tooltip for the arrow button which pops up the menu. See gtk_tool_item_set_tooltip_text() for setting a tooltip on the whole MenuToolButton.

text

text to be used as tooltip text for button’s arrow button

Sets the Menu that is popped up when the user clicks on the arrow. If menu is NULL, the arrow button becomes insensitive.

the Menu associated with MenuToolButton

The ::show-menu signal is emitted before the menu is shown.

It can be used to populate the menu on demand, using set_menu().

Note that even if you populate the menu dynamically in this way, you must set an empty menu on the MenuToolButton beforehand, since the arrow is made insensitive if the menu is not set.

Implementors