# cmd_list_windows_exec

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L59
- **Page:** https://libtmux.org/en/tmux/3.7c/reference/c-function-cmd-list-windows-c-cmd_list_windows_exec/

tmux command: [`list-windows`](/en/tmux/3.7c/manual/list-windows/)

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

## Parameters

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

## Calls

- [`args_get`](/en/tmux/3.7c/reference/c-function-args_get/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L72)
- [`args_has`](/en/tmux/3.7c/reference/c-function-args_has/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L80)
- [`cmd_get_args`](/en/tmux/3.7c/reference/c-function-cmd_get_args/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L61)
- [`cmdq_error`](/en/tmux/3.7c/reference/c-function-cmdq_error/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L77)
- [`cmdq_get_target`](/en/tmux/3.7c/reference/c-function-cmdq_get_target/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L62)
- [`cmdq_print`](/en/tmux/3.7c/reference/c-function-cmdq_print/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L107)
- [`format_add`](/en/tmux/3.7c/reference/c-function-format_add/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L96)
- [`format_defaults`](/en/tmux/3.7c/reference/c-function-format_defaults/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L97)
- [`format_expand`](/en/tmux/3.7c/reference/c-function-format_expand/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L100)
- [`format_free`](/en/tmux/3.7c/reference/c-function-format_free/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L111)
- [`format_true`](/en/tmux/3.7c/reference/c-function-format_true/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L101)
- [`sort_get_winlinks`](/en/tmux/3.7c/reference/c-function-sort_get_winlinks/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L83)
- [`sort_get_winlinks_session`](/en/tmux/3.7c/reference/c-function-sort_get_winlinks_session/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L87)
- [`sort_order_from_string`](/en/tmux/3.7c/reference/c-function-sort_order_from_string/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/cmd-list-windows.c#L75)

## Other function references

- [`cmdq_get_client`](/en/tmux/3.7c/reference/c-function-cmdq_get_client/) (function)
- [`format_create`](/en/tmux/3.7c/reference/c-function-format_create/) (function)

## Referenced by

- [`cmd_list_windows_entry`](/en/tmux/3.7c/reference/c-variable-cmd_list_windows_entry/) (attribute)

## Referenced declarations

- [`cmd`](/en/tmux/3.7c/reference/c-struct-cmd/) (struct)
- [`CMD_RETURN_ERROR`](/en/tmux/3.7c/reference/c-enum-cmd_retval-cmd_return_error/) (constant)
- [`CMD_RETURN_NORMAL`](/en/tmux/3.7c/reference/c-enum-cmd_retval-cmd_return_normal/) (constant)
- [`cmd_retval`](/en/tmux/3.7c/reference/c-enum-cmd_retval/) (enum)
- [`cmdq_item`](/en/tmux/3.7c/reference/c-struct-cmdq_item/) (struct)
- [`FORMAT_NONE`](/en/tmux/3.7c/reference/c-define-tmux-h-format_none/) (constant)
- [`format_tree.item`](/en/tmux/3.7c/reference/c-struct-format_tree-item/) (attribute)
- [`LIST_WINDOWS_TEMPLATE`](/en/tmux/3.7c/reference/c-define-cmd-list-windows-c-list_windows_template/) (constant)
- [`LIST_WINDOWS_WITH_SESSION_TEMPLATE`](/en/tmux/3.7c/reference/c-define-cmd-list-windows-c-list_windows_with_session_template/) (constant)
- [`sort_criteria.order`](/en/tmux/3.7c/reference/c-struct-sort_criteria-order/) (attribute)
- [`sort_criteria.reversed`](/en/tmux/3.7c/reference/c-struct-sort_criteria-reversed/) (attribute)
- [`cmd_find_state.s`](/en/tmux/3.7c/reference/c-struct-cmd_find_state-s/) (attribute)
- [`format_tree.s`](/en/tmux/3.7c/reference/c-struct-format_tree-s/) (attribute)
- [`winlink.session`](/en/tmux/3.7c/reference/c-struct-winlink-session/) (attribute)
- [`SORT_END`](/en/tmux/3.7c/reference/c-enum-sort_order-sort_end/) (constant)
- [`format_tree.wl`](/en/tmux/3.7c/reference/c-struct-format_tree-wl/) (attribute)
