# window_tree_draw_window

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

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

## Parameters

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

## Called by

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

## Calls

- [`format_defaults`](/en/tmux/3.7c/reference/c-function-format_defaults/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L665)
- [`format_expand`](/en/tmux/3.7c/reference/c-function-format_expand/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L684)
- [`options_get_string`](/en/tmux/3.7c/reference/c-function-options_get_string/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L682)
- [`screen_write_cursormove`](/en/tmux/3.7c/reference/c-function-screen_write_cursormove/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L635)
- [`screen_write_preview`](/en/tmux/3.7c/reference/c-function-screen_write_preview/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L680)
- [`screen_write_puts`](/en/tmux/3.7c/reference/c-function-screen_write_puts/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L638)
- [`screen_write_vline`](/en/tmux/3.7c/reference/c-function-screen_write_vline/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L636)
- [`style_apply`](/en/tmux/3.7c/reference/c-function-style_apply/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L668)
- [`window_count_panes`](/en/tmux/3.7c/reference/c-function-window_count_panes/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L582)
- [`window_tree_draw_label`](/en/tmux/3.7c/reference/c-function-window-tree-c-window_tree_draw_label/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-tree.c#L686)

## Other function references

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

## Referenced declarations

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