---
name: "Gtk2::MenuShell"
section: "3pm"
platform: "linux"
package: "libgtk2-perl-doc"
version: "2:1.24992-1"
release: "Debian 10 (Buster)"
platforms: ["linux"]
url: "https://new.carta.tech/Gtk2::MenuShell"
---

# Gtk2::MenuShell(3pm)

wrapper for GtkMenuShell

## NAME

Gtk2::MenuShell - wrapper for GtkMenuShell

## HIERARCHY

```
  Glib::Object
  +----Glib::InitiallyUnowned
       +----Gtk2::Object
            +----Gtk2::Widget
                 +----Gtk2::Container
                      +----Gtk2::MenuShell
```

## INTERFACES

```
  Glib::Object::_Unregistered::AtkImplementorIface
  Gtk2::Buildable
```

## METHODS

### $menu\_shell-\>activate\_item ($menu\_item, $force\_deactivate)

- •

  `$menu_item` (Gtk2::Widget)

- •

  `$force_deactivate` (boolean)

### $menu\_shell-\>append ($child)

- •

  `$child` (Gtk2::Widget)

### $menu\_shell-\>cancel

Since: gtk+ 2.4

### $menu\_shell-\>deactivate

### $menu\_shell-\>deselect

### $menu\_shell-\>insert ($child, $position)

- •

  `$child` (Gtk2::Widget)

- •

  `$position` (integer)

### $menu\_shell-\>prepend ($child)

- •

  `$child` (Gtk2::Widget)

### $menu\_shell-\>select\_first ($search\_sensitive)

- •

  `$search_sensitive` (boolean)

Since: gtk+ 2.2

### $menu\_shell-\>select\_item ($menu\_item)

- •

  `$menu_item` (Gtk2::Widget)

### boolean = $menu\_shell-\>get\_take\_focus

Since: gtk+ 2.8

### $menu\_shell-\>set\_take\_focus ($take\_focus)

- •

  `$take_focus` (boolean)

Since: gtk+ 2.8

## PROPERTIES

- 'take-focus' (boolean : default true : readable / writable / private)

  A boolean that determines whether the menu grabs the keyboard focus

## SIGNALS

- **activate-current** (Gtk2::MenuShell, boolean)

  - **cancel** (Gtk2::MenuShell)

  - **cycle-focus** (Gtk2::MenuShell, Gtk2::DirectionType)

  - **deactivate** (Gtk2::MenuShell)

  - **insert** (Gtk2::MenuShell, Gtk2::Widget, integer)

  - **move-current** (Gtk2::MenuShell, Gtk2::MenuDirectionType)

  - boolean = **move-selected** (Gtk2::MenuShell, integer)

  - **selection-done** (Gtk2::MenuShell)

  ## ENUMS AND FLAGS

### enum Gtk2::DirectionType

- •

  'tab-forward' / 'GTK\_DIR\_TAB\_FORWARD'

- •

  'tab-backward' / 'GTK\_DIR\_TAB\_BACKWARD'

- •

  'up' / 'GTK\_DIR\_UP'

- •

  'down' / 'GTK\_DIR\_DOWN'

- •

  'left' / 'GTK\_DIR\_LEFT'

- •

  'right' / 'GTK\_DIR\_RIGHT'

### enum Gtk2::MenuDirectionType

- •

  'parent' / 'GTK\_MENU\_DIR\_PARENT'

- •

  'child' / 'GTK\_MENU\_DIR\_CHILD'

- •

  'next' / 'GTK\_MENU\_DIR\_NEXT'

- •

  'prev' / 'GTK\_MENU\_DIR\_PREV'

## SEE ALSO

Gtk2, Glib::Object, Glib::InitiallyUnowned, Gtk2::Object, Gtk2::Widget, Gtk2::Container

## COPYRIGHT

Copyright (C) 2003-2011 by the gtk2-perl team.

This software is licensed under the LGPL.  See Gtk2 for a full notice.
