# Gtk::MenuBar Class Reference
Widgets | Menu classes

A standard menu bar which usually holds Gtk::Menu submenu items. More...

Inheritance diagram for Gtk::MenuBar:
[legend]
Collaboration diagram for Gtk::MenuBar:
[legend]

List of all members.

## Public Member Functions

virtual | ~MenuBar ()
GtkMenuBar* | gobj ()
| Provides access to the underlying C GtkObject.
const GtkMenuBar* | gobj () const
| Provides access to the underlying C GtkObject.
| MenuBar ()
PackDirection | get_pack_direction () const
| Retrieves the current pack direction of the menubar.
void | set_pack_direction (PackDirection pack_dir)
| Sets how items should be packed inside a menubar.
PackDirection | get_child_pack_direction () const
| Retrieves the current child pack direction of the menubar.
void | set_child_pack_direction (PackDirection child_pack_dir)
| Sets how widgets should be packed inside the children of a menubar.
Glib::PropertyProxy < PackDirection > | property_pack_direction ()
| The pack direction of the menubar.
Glib::PropertyProxy_ReadOnly < PackDirection > | property_pack_direction () const
| The pack direction of the menubar.
Glib::PropertyProxy < PackDirection > | property_child_pack_direction ()
| The child pack direction of the menubar.
Glib::PropertyProxy_ReadOnly < PackDirection > | property_child_pack_direction () const
| The child pack direction of the menubar.

## Related Functions

(Note that these are not member functions.)
Gtk::MenuBar* | wrap (GtkMenuBar* object, bool take_copy=false)
| A Glib::wrap() method for this object.

## Detailed Description

A standard menu bar which usually holds Gtk::Menu submenu items.

The useful methods are in the base class - Gtk::MenuShell.

The MenuBar widget looks like this:

## Constructor & Destructor Documentation

virtual Gtk::MenuBar::~MenuBar | ( |  | ) | `[virtual]`

Gtk::MenuBar::MenuBar | ( |  | ) |

## Member Function Documentation

PackDirection Gtk::MenuBar::get_child_pack_direction | ( |  | ) | const

Retrieves the current child pack direction of the menubar.

See set_child_pack_direction().

Since gtkmm 2.8:

Returns:
  The child pack direction.

PackDirection Gtk::MenuBar::get_pack_direction | ( |  | ) | const

Retrieves the current pack direction of the menubar.

See set_pack_direction().

Since gtkmm 2.8:

Returns:
  The pack direction.

const GtkMenuBar* Gtk::MenuBar::gobj | ( |  | ) | const`[inline]`

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::MenuShell.

GtkMenuBar* Gtk::MenuBar::gobj | ( |  | ) | `[inline]`

Provides access to the underlying C GtkObject.

Reimplemented from Gtk::MenuShell.

Glib::PropertyProxy<PackDirection> Gtk::MenuBar::property_child_pack_direction | ( |  | ) |

The child pack direction of the menubar.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<PackDirection> Gtk::MenuBar::property_child_pack_direction | ( |  | ) | const

The child pack direction of the menubar.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<PackDirection> Gtk::MenuBar::property_pack_direction | ( |  | ) | const

The pack direction of the menubar.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<PackDirection> Gtk::MenuBar::property_pack_direction | ( |  | ) |

The pack direction of the menubar.

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

void Gtk::MenuBar::set_child_pack_direction | ( | PackDirection | child_pack_dir | ) |

Sets how widgets should be packed inside the children of a menubar.

Since gtkmm 2.8:

Parameters:

  child_pack_dir | A new Gtk::PackDirection.

void Gtk::MenuBar::set_pack_direction | ( | PackDirection | pack_dir | ) |

Sets how items should be packed inside a menubar.

Since gtkmm 2.8:

Parameters:

  pack_dir | A new Gtk::PackDirection.

## Friends And Related Function Documentation

Gtk::MenuBar* wrap | ( | GtkMenuBar * | object,
|  | bool | take_copy = `false`
| ) |  | `[related]`

A Glib::wrap() method for this object.

Parameters:

  object | The C instance.
  take_copy | False if the result should take ownership of the C instance. True if it should take a new copy or ref.

Returns:
  A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file:

- gtkmm/menubar.h