# layout_split_pane

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

```c
struct layout_cell * layout_split_pane(struct window_pane *wp, enum layout_type type, int size, int flags)
```

## Parameters

- `wp` (`struct window_pane *`)
- `type` (`enum layout_type`)
- `size` (`int`)
- `flags` (`int`)

## Called by

- [`cmd_join_pane_exec`](/en/tmux/3.2a/reference/c-function-cmd-join-pane-c-cmd_join_pane_exec/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/cmd-join-pane.c#L130)
- [`cmd_split_window_exec`](/en/tmux/3.2a/reference/c-function-cmd-split-window-c-cmd_split_window_exec/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/cmd-split-window.c#L124)

## Calls

- [`fatalx`](/en/tmux/3.2a/reference/c-function-fatalx/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L908)
- [`layout_add_border`](/en/tmux/3.2a/reference/c-function-layout-c-layout_add_border/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L900)
- [`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#L947)
- [`layout_fix_offsets`](/en/tmux/3.2a/reference/c-function-layout_fix_offsets/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L1028)
- [`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#L1030)
- [`layout_make_node`](/en/tmux/3.2a/reference/c-function-layout_make_node/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L988)
- [`layout_resize_child_cells`](/en/tmux/3.2a/reference/c-function-layout-c-layout_resize_child_cells/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L961)
- [`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#L974)
- [`options_get_number`](/en/tmux/3.2a/reference/c-function-options_get_number/) (function) [Call site](https://github.com/tmux/tmux/blob/3b929f332aafa7f1080eacc31feb11ffbb1d1841/layout.c#L885)

## Other function references

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

## Referenced by

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

## Referenced declarations

- [`layout_cell.cells`](/en/tmux/3.2a/reference/c-struct-layout_cell-cells/) (attribute)
- [`layout_cell.entry`](/en/tmux/3.2a/reference/c-struct-layout_cell-entry/) (attribute)
- [`layout_cell`](/en/tmux/3.2a/reference/c-struct-layout_cell/) (struct)
- [`window_pane.layout_cell`](/en/tmux/3.2a/reference/c-struct-window_pane-layout_cell/) (attribute)
- [`LAYOUT_LEFTRIGHT`](/en/tmux/3.2a/reference/c-enum-layout_type-layout_leftright/) (constant)
- [`window.layout_root`](/en/tmux/3.2a/reference/c-struct-window-layout_root/) (attribute)
- [`LAYOUT_TOPBOTTOM`](/en/tmux/3.2a/reference/c-enum-layout_type-layout_topbottom/) (constant)
- [`layout_type`](/en/tmux/3.2a/reference/c-enum-layout_type/) (enum)
- [`window.options`](/en/tmux/3.2a/reference/c-struct-window-options/) (attribute)
- [`PANE_MINIMUM`](/en/tmux/3.2a/reference/c-define-tmux-h-pane_minimum/) (constant)
- [`layout_cell.parent`](/en/tmux/3.2a/reference/c-struct-layout_cell-parent/) (attribute)
- [`SPAWN_BEFORE`](/en/tmux/3.2a/reference/c-define-tmux-h-spawn_before/) (constant)
- [`SPAWN_FULLSIZE`](/en/tmux/3.2a/reference/c-define-tmux-h-spawn_fullsize/) (constant)
- [`layout_cell.sx`](/en/tmux/3.2a/reference/c-struct-layout_cell-sx/) (attribute)
- [`layout_cell.sy`](/en/tmux/3.2a/reference/c-struct-layout_cell-sy/) (attribute)
- [`layout_cell.type`](/en/tmux/3.2a/reference/c-struct-layout_cell-type/) (attribute)
- [`window_pane.window`](/en/tmux/3.2a/reference/c-struct-window_pane-window/) (attribute)
- [`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)
- [`layout_cell.xoff`](/en/tmux/3.2a/reference/c-struct-layout_cell-xoff/) (attribute)
- [`layout_cell.yoff`](/en/tmux/3.2a/reference/c-struct-layout_cell-yoff/) (attribute)
