# format_grid_line

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/format.c#L6080
- **Page:** https://libtmux.org/en/tmux/latest/reference/c-function-format_grid_line/

```c
char * format_grid_line(struct grid *gd, u_int y)
```

## Parameters

- `gd` (`struct grid *`)
- `y` (`u_int`)

## Called by

- [`format_cb_mouse_line`](/en/tmux/latest/reference/c-function-format-c-format_cb_mouse_line/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/format.c#L1301)
- [`window_copy_get_line`](/en/tmux/latest/reference/c-function-window_copy_get_line/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/window-copy.c#L913)

## Calls

- [`grid_get_cell`](/en/tmux/latest/reference/c-function-grid_get_cell/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/format.c#L6089)
- [`utf8_set`](/en/tmux/latest/reference/c-function-utf8_set/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/format.c#L6095)
- [`utf8_tocstr`](/en/tmux/latest/reference/c-function-utf8_tocstr/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/format.c#L6101)
- [`xreallocarray`](/en/tmux/latest/reference/c-function-xreallocarray/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/format.c#L6093)

## Other function references

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

## Referenced declarations

- [`grid_cell.data`](/en/tmux/latest/reference/c-struct-grid_cell-data/) (attribute)
- [`grid_cell.flags`](/en/tmux/latest/reference/c-struct-grid_cell-flags/) (attribute)
- [`grid`](/en/tmux/latest/reference/c-struct-grid/) (struct)
- [`GRID_FLAG_PADDING`](/en/tmux/latest/reference/c-define-tmux-h-grid_flag_padding/) (constant)
- [`GRID_FLAG_TAB`](/en/tmux/latest/reference/c-define-tmux-h-grid_flag_tab/) (constant)
- [`utf8_data.size`](/en/tmux/latest/reference/c-struct-utf8_data-size/) (attribute)
