# layout_init

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L478
- **Page:** https://libtmux.org/en/tmux/3.2a/reference/c-function-layout_init/

```c
void layout_init(struct window *w, struct window_pane *wp)
```

## Parameters

- `w` (`struct window *`)
- `wp` (`struct window_pane *`)

## Called by

- [`cmd_break_pane_exec`](/en/tmux/3.2a/reference/c-function-cmd-break-pane-c-cmd_break_pane_exec/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/cmd-break-pane.c#L116)
- [`spawn_pane`](/en/tmux/3.2a/reference/c-function-spawn_pane/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/spawn.c#L259)
- [`spawn_window`](/en/tmux/3.2a/reference/c-function-spawn_window/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/spawn.c#L115)
- [`window_zoom`](/en/tmux/3.2a/reference/c-function-window_zoom/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/window.c#L603)

## Calls

- [`layout_create_cell`](/en/tmux/3.2a/reference/c-function-layout_create_cell/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L482)
- [`layout_fix_panes`](/en/tmux/3.2a/reference/c-function-layout_fix_panes/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L485)
- [`layout_make_leaf`](/en/tmux/3.2a/reference/c-function-layout_make_leaf/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L484)
- [`layout_set_size`](/en/tmux/3.2a/reference/c-function-layout_set_size/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L483)

## Referenced by

- [`server_client_push_stderr`](/en/tmux/3.2a/reference/c-function-server_client_push_stderr/) (function)

## Referenced declarations

- [`window.layout_root`](/en/tmux/3.2a/reference/c-struct-window-layout_root/) (attribute)
- [`window.sx`](/en/tmux/3.2a/reference/c-struct-window-sx/) (attribute)
- [`window.sy`](/en/tmux/3.2a/reference/c-struct-window-sy/) (attribute)
- [`window`](/en/tmux/3.2a/reference/c-struct-window/) (struct)
- [`window_pane`](/en/tmux/3.2a/reference/c-struct-window_pane/) (struct)
- [`layout_cell.wp`](/en/tmux/3.2a/reference/c-struct-layout_cell-wp/) (attribute)
