# window_tree_draw_session

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L429
- **Page:** https://libtmux.org/en/tmux/latest/reference/c-function-window-tree-c-window_tree_draw_session/

```c
static void window_tree_draw_session(struct window_tree_modedata *data, struct session *s, struct screen_write_ctx *ctx, u_int sx, u_int sy)
```

## Parameters

- `data` (`struct window_tree_modedata *`)
- `s` (`struct session *`)
- `ctx` (`struct screen_write_ctx *`)
- `sx` (`u_int`)
- `sy` (`u_int`)

## Called by

- [`window_tree_draw`](/en/tmux/latest/reference/c-function-window-tree-c-window_tree_draw/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L720)

## Calls

- [`format_defaults`](/en/tmux/latest/reference/c-function-format_defaults/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L528)
- [`format_expand`](/en/tmux/latest/reference/c-function-format_expand/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L547)
- [`options_get_string`](/en/tmux/latest/reference/c-function-options_get_string/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L545)
- [`screen_write_cursormove`](/en/tmux/latest/reference/c-function-screen_write_cursormove/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L497)
- [`screen_write_preview`](/en/tmux/latest/reference/c-function-screen_write_preview/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L543)
- [`screen_write_puts`](/en/tmux/latest/reference/c-function-screen_write_puts/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L500)
- [`screen_write_vline`](/en/tmux/latest/reference/c-function-screen_write_vline/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L498)
- [`style_apply`](/en/tmux/latest/reference/c-function-style_apply/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L531)
- [`window_tree_draw_label`](/en/tmux/latest/reference/c-function-window-tree-c-window_tree_draw_label/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L549)
- [`winlink_count`](/en/tmux/latest/reference/c-function-winlink_count/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L444)

## Other function references

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

## Referenced declarations

- [`window.active`](/en/tmux/latest/reference/c-struct-window-active/) (attribute)
- [`window_pane.base`](/en/tmux/latest/reference/c-struct-window_pane-base/) (attribute)
- [`session.curw`](/en/tmux/latest/reference/c-struct-session-curw/) (attribute)
- [`screen.cx`](/en/tmux/latest/reference/c-struct-screen-cx/) (attribute)
- [`screen.cy`](/en/tmux/latest/reference/c-struct-screen-cy/) (attribute)
- [`window_tree_modedata.each`](/en/tmux/latest/reference/c-struct-window_tree_modedata-each/) (attribute)
- [`window_tree_modedata.end`](/en/tmux/latest/reference/c-struct-window_tree_modedata-end/) (attribute)
- [`FORMAT_WINDOW`](/en/tmux/latest/reference/c-define-tmux-h-format_window/) (constant)
- [`grid_default_cell`](/en/tmux/latest/reference/c-variable-grid_default_cell/) (attribute)
- [`window.id`](/en/tmux/latest/reference/c-struct-window-id/) (attribute)
- [`window_tree_modedata.left`](/en/tmux/latest/reference/c-struct-window_tree_modedata-left/) (attribute)
- [`window_tree_modedata.offset`](/en/tmux/latest/reference/c-struct-window_tree_modedata-offset/) (attribute)
- [`window.options`](/en/tmux/latest/reference/c-struct-window-options/) (attribute)
- [`window_tree_modedata.right`](/en/tmux/latest/reference/c-struct-window_tree_modedata-right/) (attribute)
- [`screen_write_ctx.s`](/en/tmux/latest/reference/c-struct-screen_write_ctx-s/) (attribute)
- [`screen_write_ctx`](/en/tmux/latest/reference/c-struct-screen_write_ctx/) (struct)
- [`session`](/en/tmux/latest/reference/c-struct-session/) (struct)
- [`window_tree_modedata.start`](/en/tmux/latest/reference/c-struct-window_tree_modedata-start/) (attribute)
- [`winlink.window`](/en/tmux/latest/reference/c-struct-winlink-window/) (attribute)
- [`window_tree_modedata`](/en/tmux/latest/reference/c-struct-window_tree_modedata/) (struct)
- [`session.windows`](/en/tmux/latest/reference/c-struct-session-windows/) (attribute)
