index
gtk-- homepage



Description:
Gtk_Menu

#include <gtk--/menu.h>
Base classes: Gtk_MenuShell



Properties:


Public member index:


static GtkType get_type();
GtkMenu *gtkobj();
const GtkMenu *gtkobj()const;
static bool isA(Gtk_Object *checkcast);
virtual ~Gtk_Menu();
Gtk_Menu();
void append(Gtk_MenuItem &child);
append a menu item

void prepend(Gtk_MenuItem &child);
insert a menu item in first position

void insert(Gtk_MenuItem &child,gint position);
insert a menu item at specified position

void popup(Gtk_MenuShell &parent_menu_shell,Gtk_MenuItem &parent_menu_item,GtkMenuPositionFunc func,gpointer data,guint button,guint32 activate_time);
Display the menu on screen

void popup(GtkMenuPositionFunc func,gpointer data,guint button,guint32 activate_time);
void popdown();
Hides the menu away

Gtk_MenuItem *get_active()const;
void set_active(gint index);
void reposition();
void set_accel_group(Gtk_AccelGroup *accel_group=0);
void set_accel_group(Gtk_AccelGroup &accel_group);
Gtk_AccelGroup *get_accel_group()const;
Gtk_AccelGroup *get_uline_accel_group()const;
Gtk_AccelGroup *ensure_uline_accel_group()const;
void set_tearoff_state(bool torn_off);
void set_title(const gtkmm_string &title);
void reorder_child(const Gtk_MenuItem &child,gint position);
Gtk_Widget *get_attach_widget()const;
void detach();
Protected member index:


void initialize_class();
void *get_parent_class();
static void init_parent_class();
explicit Gtk_Menu(GtkMenu *castitem);
void attach_to_widget(Gtk_Widget &widget,GtkMenuDetachFunc detacher);
Private member index:


Gtk_Menu(const Gtk_Menu &);
Gtk_Menu &operator =(const Gtk_Menu &);

Public member details:


get_active
Gtk_MenuItem *Gtk_Menu::get_active()const;

Keep track of the last menu item selected, for the purposes of the option menu


reposition
void Gtk_Menu::reposition();

Position the menu according to it's position function. This wraps a function called by gtkmenuitem.c when a menu-item changes its allocation. You most likely don't need to care about it.


set_title
void Gtk_Menu::set_title(const gtkmm_string &title);

Sets the window manager title for the window that appears when a menu is torn off


detach
void Gtk_Menu::detach();

Detach the menu from the widget it was attached to (calls the passed detacher function)


Protected member details:



attach_to_widget
void Gtk_Menu::attach_to_widget(Gtk_Widget &widget,GtkMenuDetachFunc detacher);

Attach the menu to a widget. detacher is a function which takes the attached GtkWidget* and GtkMenu* (NOTE! NOT the Gtk_Widget and Gtk_Menu!) This is mostly used by other widgets like Gtk_MenuItem or Gtk_NoteBook. You probably don't need to care about it.


Private member details:




Examples:





(pages generated by PERCEPS -script.)