Description Methods and Functions Hierarchy Interfaces Detailed Description Structures Convenient Construction Signals Properties Author(s) References
A GtkToolItem containing a button with an additional dropdown menu
gtkMenuToolButtonNew(icon.widget, label, show = TRUE)
gtkMenuToolButtonNewFromStock(stock.id)
gtkMenuToolButtonSetMenu(object, menu)
gtkMenuToolButtonGetMenu(object)
gtkMenuToolButtonSetArrowTooltip(object, tooltips, tip.text = NULL, tip.private = NULL)
gtkMenuToolButtonSetArrowTooltip(object, tooltips, tip.text = NULL, tip.private = NULL)
gtkMenuToolButtonSetArrowTooltipText(object, text)
gtkMenuToolButtonSetArrowTooltipMarkup(object, markup)
gtkMenuToolButton(icon.widget, label, show = TRUE)
1 2 3 4 5 6 7 8 9 | GObject
+----GInitiallyUnowned
+----GtkObject
+----GtkWidget
+----GtkContainer
+----GtkBin
+----GtkToolItem
+----GtkToolButton
+----GtkMenuToolButton
|
GtkMenuToolButton implements
AtkImplementorIface, GtkBuildable
and GtkActivatable
.
A GtkMenuToolButton
is a GtkToolItem
that contains a button and
a small additional button with an arrow. When clicked, the arrow
button pops up a dropdown menu.
Use gtkMenuToolButtonNew
to create a new
GtkMenuToolButton
. Use gtkMenuToolButtonNewFromStock
to
create a new GtkMenuToolButton
containing a stock item.
GtkMenuToolButton
The GtkMenuToolButton
struct contains only private data and
should only be accessed through the functions described below.
gtkMenuToolButton
is the equivalent of gtkMenuToolButtonNew
.
show-menu(button, user.data)
The ::show-menu signal is emitted before the menu is shown.
It can be used to populate the menu on demand, using
gtkMenuToolButtonGetMenu
.
Note that even if you populate the menu dynamically in this way,
you must set an empty menu on the GtkMenuToolButton
beforehand,
since the arrow is made insensitive if the menu is not set.
button
the object on which the signal is emitted
user.data
user data set when the signal handler was connected.
menu
[GtkMenu
: * : Read / Write]The dropdown menu.
Derived by RGtkGen from GTK+ documentation
https://developer.gnome.org/gtk2/stable/GtkMenuToolButton.html
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.