Gtk_Menu(3)

NAME - Gtk_Menu

HEADER REQUIRED
#include <gtk--/menu.h&gt;>

BASE CLASSES
Gtk_MenuShell(3)

PROPERTIES

parent_menu_item
    Type: Gtk_Widget*
    Get: none
    Set: popup()

accel_group
    Type: GtkAccelGroup*
    Set: set_accel_group()

position_func
    Type: GtkMenuPositionFunc
    Get: none
    Set: popup()

     A function taking a GtkMenu* ({ NOTE! NOT a Gtk_Menu!}), pointers to x and y gint coordinates and a pointer to some user data. The function should set x and y to where the menu will be positioned on the screen

position_func_data
    Type: gpointer
    Get: none
    Set: popup()

     user data which will be passed to position_func

torn_off
    Type: bool
    Get: none
    Set: set_tearoff_state()

     Whether the menu is torn off (detached) or not.

PUBLIC MEMBER INDEX
    Gtk_Menu();
    ~Gtk_Menu();
    Gtk_Menu(GtkMenu *castitem);
    void  append(const Gtk_MenuItem &child);
      append a menu item
    void  prepend(const Gtk_MenuItem &child);
      insert a menu item in first position
    void  insert(const Gtk_MenuItem &child, gint position);
      insert a menu item at specified position
    void  append(const Gtk_ObjectHandle &child);
    void  prepend(const Gtk_ObjectHandle &child);
    void  insert(const Gtk_ObjectHandle &child, gint position);
    void  popup(const Gtk_MenuShell &parent_menu_shell, const Gtk_MenuItem &parent_menu_item, GtkMenuPositionFunc func, gpointer data, gint button, guint32 activate_time);
      Display the menu on screen
    void  popup(GtkMenuPositionFunc func, gpointer data, gint button, guint32 activate_time);
    void  popdown();
      Hides the menu away
    const Gtk_MenuItem*  get_active() const;
    Gtk_MenuItem*  get_active();
    void  set_active(gint index);
    void  reposition();
    void  set_accel_group(Gtk_AccelGroup &accel_group);
    Gtk_AccelGroup*  get_accel_group();
    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 _gtk_string &title);
    void  reorder_child(const Gtk_MenuItem &child, gint position);
    void  attach_to_widget(const Gtk_Widget &widget, GtkMenuDetachFunc detacher);
    const Gtk_Widget*  get_attach_widget() const;
    Gtk_Widget*  get_attach_widget();
    void  detach();
    GtkMenu*  gtkobj();
    const GtkMenu*  gtkobj() const;
    static bool  isGtkMenu(Gtk_Object *checkcast);

PROTECTED MEMBER INDEX
    friend  CppClassType;
    typedef GtkMenu  BaseObjectType;
    typedef GtkMenuClass  BaseClassType;
    virtual void * get_parent_class();
    mutable Gtk_ObjectHandle  active_widget_;
    mutable Gtk_Widget * attach_widget_;
    Gtk_ObjectHandle  accel_group_;
    mutable Gtk_ObjectHandle  uline_accel_group_;

PRIVATE MEMBER INDEX
    static CppClassType  menu_class;
    GtkType  get_type();
    const Gtk_MenuItem*  _get_active() const;

PUBLIC MEMBER DESCRIPTIONS

void  Gtk_Menu::append (const Gtk_ObjectHandle &child);
    same, except that the item will be "owned" by the menu widget. That is, the widget will destroy it along when it is deleted

const Gtk_MenuItem*  Gtk_Menu::get_active () const;
    Keep track of the last menu item selected, for the purposes of the option menu

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.

void  Gtk_Menu::set_title (const _gtk_string &title);
    Sets the window manager title for the window that appears when a menu is torn off

void  Gtk_Menu::attach_to_widget (const 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.

void  Gtk_Menu::detach ();
    Detach the menu from the widget it was attached to (calls the passed detacher function)

PROTECTED MEMBER DESCRIPTIONS

PRIVATE MEMBER DESCRIPTIONS