gtk2/docs/reference/gtk/tmpl/gtkmenuitem.sgml
Owen Taylor 11aed263b7 Set the width of the layout to the actual wrap width (our requisition) not
Tue May 14 16:44:09 2002  Owen Taylor  <otaylor@redhat.com>

        * gtk/gtklabel.c (gtk_label_ensure_layout): Set
        the width of the layout to the actual wrap width
        (our requisition) not the width we set when calculating
        the width. This results in the lines being justified
        within the correct area. (#79157, Anders Carlsson)

        * gtk/gtkaccelgroup.c gtk/gtkmarshelers.list: Corrected
        registered parameter types of "accel_activate" and
        "accel_changed" signals. (Patch from Murray Cumming, #78798)

        * gtk/gtkrc.c (gtk_rc_make_default_dir): Switch
        binary-version and type to correspond to the
        current ordering in _gtk_get_module_path.
        (#78746, Sergey Kuzminov)

        * gtk/gtkrc.c (gtk_rc_get_module_dir): Add docs
        pointing to the GTK_PATH documentation.

        * gtk/Makefile.am (uninstall-local): Delete
        key themes as well. (#81286, Kristian Rietveld.)
2002-05-14 20:55:22 +00:00

209 lines
4.0 KiB
Plaintext

<!-- ##### SECTION Title ##### -->
GtkMenuItem
<!-- ##### SECTION Short_Description ##### -->
the widget used for item in menus
<!-- ##### SECTION Long_Description ##### -->
<para>
The #GtkMenuItem widget and the derived widgets are the only valid
childs for menus. Their function is to correctly handle highlighting,
alignment, events and submenus.
</para>
<para>
As it derives from #GtkBin it can hold any valid child widget, altough
only a few are really useful.
</para>
<!-- ##### SECTION See_Also ##### -->
<para>
<variablelist>
<varlistentry>
<term>#GtkBin</term>
<listitem><para>for how to handle the child.</para></listitem>
</varlistentry>
<varlistentry>
<term>#GtkItem</term>
<listitem><para>is the abstract class for all sorts of items.</para></listitem>
</varlistentry>
<varlistentry>
<term>#GtkMenuShell</term>
<listitem><para>is always the parent of #GtkMenuItem.</para></listitem>
</varlistentry>
</variablelist>
</para>
<!-- ##### STRUCT GtkMenuItem ##### -->
<para>
</para>
<!-- ##### FUNCTION gtk_menu_item_new ##### -->
<para>
Creates a new #GtkMenuItem.
</para>
@Returns: the newly created #GtkMenuItem
<!-- ##### FUNCTION gtk_menu_item_new_with_label ##### -->
<para>
Creates a new #GtkMenuItem whose child is a #GtkLabel.
</para>
@label: the text for the label
@Returns: the newly created #GtkMenuItem
<!-- ##### FUNCTION gtk_menu_item_new_with_mnemonic ##### -->
<para>
</para>
@label:
@Returns:
<!-- ##### FUNCTION gtk_menu_item_set_right_justified ##### -->
<para>
</para>
@menu_item:
@right_justified:
<!-- ##### FUNCTION gtk_menu_item_set_submenu ##### -->
<para>
Sets the widget submenu, or changes it.
</para>
@menu_item: the menu item widget
@submenu: the submenu
<!-- ##### FUNCTION gtk_menu_item_set_accel_path ##### -->
<para>
</para>
@menu_item:
@accel_path:
<!-- ##### FUNCTION gtk_menu_item_remove_submenu ##### -->
<para>
Removes the widget's submenu.
</para>
@menu_item: the menu item widget
<!-- ##### FUNCTION gtk_menu_item_select ##### -->
<para>
Emits the "select" signal on the given item. Behaves exactly like
#gtk_item_select.
</para>
@menu_item: the menu item
<!-- ##### FUNCTION gtk_menu_item_deselect ##### -->
<para>
Emits the "deselect" signal on the given item. Behaves exactly like
#gtk_item_deselect.
</para>
@menu_item: the menu item
<!-- ##### FUNCTION gtk_menu_item_activate ##### -->
<para>
Emits the "activate" signal on the given item
</para>
@menu_item: the menu item
<!-- ##### FUNCTION gtk_menu_item_toggle_size_request ##### -->
<para>
Emits the "toggle_size_request" signal on the given item.
</para>
@menu_item: the menu item
@requisition: the requisition to use as signal data.
<!-- ##### FUNCTION gtk_menu_item_toggle_size_allocate ##### -->
<para>
Emits the "toggle_size_allocate" signal on the given item.
</para>
@menu_item: the menu item.
@allocation: the allocation to use as signal data.
<!-- ##### MACRO gtk_menu_item_right_justify ##### -->
<para>
Sets the menu item to be right-justified. Only useful for menu bars.
</para>
@menu_item: the menu item
<!-- ##### FUNCTION gtk_menu_item_get_right_justified ##### -->
<para>
</para>
@menu_item:
@Returns:
<!-- ##### FUNCTION gtk_menu_item_get_submenu ##### -->
<para>
</para>
@menu_item:
@Returns:
<!-- ##### SIGNAL GtkMenuItem::activate ##### -->
<para>
Emitted when the item is activated.
</para>
@menuitem: the object which received the signal.
<!-- ##### SIGNAL GtkMenuItem::activate-item ##### -->
<para>
Emitted when the item is activated, but also if the menu item has a
submenu. For normal applications, the relevant signal is "activate".
</para>
@menuitem: the object which received the signal.
<!-- ##### SIGNAL GtkMenuItem::toggle-size-allocate ##### -->
<para>
</para>
@menuitem: the object which received the signal.
@arg1:
<!-- ##### SIGNAL GtkMenuItem::toggle-size-request ##### -->
<para>
</para>
@menuitem: the object which received the signal.
@arg1:
<!-- ##### ARG GtkMenuItem:selected-shadow-type ##### -->
<para>
</para>