Method

GtkMenuattach_to_widget

Declaration [src]

void
gtk_menu_attach_to_widget (
  GtkMenu* menu,
  GtkWidget* attach_widget,
  GtkMenuDetachFunc detacher
)

Description [src]

Attaches the menu to the widget and provides a callback function that will be invoked when the menu calls gtk_menu_detach() during its destruction.

If the menu is attached to the widget then it will be destroyed when the widget is destroyed, as if it was a child widget. An attached menu will also move between screens correctly if the widgets moves between screens.

Parameters

attach_widget GtkWidget
 

The GtkWidget that the menu will be attached to.

 The data is owned by the caller of the function.
detacher GtkMenuDetachFunc
 

The user supplied callback function that will be called when the menu calls gtk_menu_detach()