# cmd_display_menu_exec

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L284
- **Page:** https://libtmux.org/en/tmux/latest/reference/c-function-cmd-display-menu-c-cmd_display_menu_exec/

tmux command: [`display-menu`](/en/tmux/latest/manual/display-menu/)

```c
static enum cmd_retval cmd_display_menu_exec(struct cmd *, struct cmdq_item *)
```

## Parameters

- `self` (`struct cmd *`)
- `item` (`struct cmdq_item *`)

## Calls

- [`args_count`](/en/tmux/latest/reference/c-function-args_count/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L299)
- [`args_get`](/en/tmux/latest/reference/c-function-args_get/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L293)
- [`args_has`](/en/tmux/latest/reference/c-function-args_has/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L307)
- [`args_string`](/en/tmux/latest/reference/c-function-args_string/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L328)
- [`args_strtonum`](/en/tmux/latest/reference/c-function-args_strtonum/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L311)
- [`cmd_display_menu_get_pos`](/en/tmux/latest/reference/c-function-cmd-display-menu-c-cmd_display_menu_get_pos/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L352)
- [`cmd_get_args`](/en/tmux/latest/reference/c-function-cmd_get_args/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L286)
- [`cmdq_error`](/en/tmux/latest/reference/c-function-cmdq_error/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L314)
- [`cmdq_get_event`](/en/tmux/latest/reference/c-function-cmdq_get_event/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L288)
- [`cmdq_get_target`](/en/tmux/latest/reference/c-function-cmdq_get_target/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L287)
- [`cmdq_get_target_client`](/en/tmux/latest/reference/c-function-cmdq_get_target_client/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L289)
- [`format_single_from_target`](/en/tmux/latest/reference/c-function-format_single_from_target/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L321)
- [`key_string_lookup_string`](/en/tmux/latest/reference/c-function-key_string_lookup_string/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L341)
- [`menu_add_item`](/en/tmux/latest/reference/c-function-menu_add_item/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L330)
- [`menu_create`](/en/tmux/latest/reference/c-function-menu_create/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L324)
- [`menu_display`](/en/tmux/latest/reference/c-function-menu_display/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L371)
- [`menu_free`](/en/tmux/latest/reference/c-function-menu_free/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L377)
- [`options_find_choice`](/en/tmux/latest/reference/c-function-options_find_choice/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L359)
- [`options_get`](/en/tmux/latest/reference/c-function-options_get/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L358)
- [`xstrdup`](/en/tmux/latest/reference/c-function-xstrdup/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-display-menu.c#L323)

## Referenced by

- [`cmd_display_menu_entry`](/en/tmux/latest/reference/c-variable-cmd_display_menu_entry/) (attribute)

## Referenced declarations

- [`BOX_LINES_DEFAULT`](/en/tmux/latest/reference/c-enum-box_lines-box_lines_default/) (constant)
- [`cmd`](/en/tmux/latest/reference/c-struct-cmd/) (struct)
- [`CMD_RETURN_ERROR`](/en/tmux/latest/reference/c-enum-cmd_retval-cmd_return_error/) (constant)
- [`CMD_RETURN_NORMAL`](/en/tmux/latest/reference/c-enum-cmd_retval-cmd_return_normal/) (constant)
- [`CMD_RETURN_WAIT`](/en/tmux/latest/reference/c-enum-cmd_retval-cmd_return_wait/) (constant)
- [`cmd_retval`](/en/tmux/latest/reference/c-enum-cmd_retval/) (enum)
- [`cmdq_item`](/en/tmux/latest/reference/c-struct-cmdq_item/) (struct)
- [`menu_item.command`](/en/tmux/latest/reference/c-struct-menu_item-command/) (attribute)
- [`menu.count`](/en/tmux/latest/reference/c-struct-menu-count/) (attribute)
- [`session.curw`](/en/tmux/latest/reference/c-struct-session-curw/) (attribute)
- [`menu_item.key`](/en/tmux/latest/reference/c-struct-menu_item-key/) (attribute)
- [`MENU_NOMOUSE`](/en/tmux/latest/reference/c-define-tmux-h-menu_nomouse/) (constant)
- [`MENU_STAYOPEN`](/en/tmux/latest/reference/c-define-tmux-h-menu_stayopen/) (constant)
- [`menu_item.name`](/en/tmux/latest/reference/c-struct-menu_item-name/) (attribute)
- [`options_entry.name`](/en/tmux/latest/reference/c-struct-options_entry-name/) (attribute)
- [`window.options`](/en/tmux/latest/reference/c-struct-window-options/) (attribute)
- [`client.overlay_draw`](/en/tmux/latest/reference/c-struct-client-overlay_draw/) (attribute)
- [`cmd_find_state.s`](/en/tmux/latest/reference/c-struct-cmd_find_state-s/) (attribute)
- [`options_entry.value`](/en/tmux/latest/reference/c-struct-options_entry-value/) (attribute)
- [`menu.width`](/en/tmux/latest/reference/c-struct-menu-width/) (attribute)
- [`winlink.window`](/en/tmux/latest/reference/c-struct-winlink-window/) (attribute)
