# tty_clear_line

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

```c
static void tty_clear_line(struct tty *tty, const struct grid_cell *defaults, u_int py, u_int px, u_int nx, u_int bg)
```

## Parameters

- `tty` (`struct tty *`)
- `defaults` (`const struct grid_cell *`)
- `py` (`u_int`)
- `px` (`u_int`)
- `nx` (`u_int`)
- `bg` (`u_int`)

## Called by

- [`tty_clear_area`](/en/tmux/latest/reference/c-function-tty-c-tty_clear_area/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1386)
- [`tty_clear_pane_line`](/en/tmux/latest/reference/c-function-tty-c-tty_clear_pane_line/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1245)

## Calls

- [`log_debug`](/en/tmux/latest/reference/c-function-log_debug/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1183)
- [`tty_check_overlay_range`](/en/tmux/latest/reference/c-function-tty_check_overlay_range/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1217)
- [`tty_cursor`](/en/tmux/latest/reference/c-function-tty_cursor/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1193)
- [`tty_putcode`](/en/tmux/latest/reference/c-function-tty_putcode/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1194)
- [`tty_putcode_i`](/en/tmux/latest/reference/c-function-tty_putcode_i/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1208)
- [`tty_repeat_space`](/en/tmux/latest/reference/c-function-tty_repeat_space/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1222)
- [`tty_term_has`](/en/tmux/latest/reference/c-function-tty_term_has/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/tty.c#L1206)

## Other function references

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

## Referenced declarations

- [`tty.client`](/en/tmux/latest/reference/c-struct-tty-client/) (attribute)
- [`grid_cell`](/en/tmux/latest/reference/c-struct-grid_cell/) (struct)
- [`client.name`](/en/tmux/latest/reference/c-struct-client-name/) (attribute)
- [`visible_range.nx`](/en/tmux/latest/reference/c-struct-visible_range-nx/) (attribute)
- [`client.overlay_check`](/en/tmux/latest/reference/c-struct-client-overlay_check/) (attribute)
- [`visible_range.px`](/en/tmux/latest/reference/c-struct-visible_range-px/) (attribute)
- [`visible_ranges.ranges`](/en/tmux/latest/reference/c-struct-visible_ranges-ranges/) (attribute)
- [`tty.sx`](/en/tmux/latest/reference/c-struct-tty-sx/) (attribute)
- [`tty.term`](/en/tmux/latest/reference/c-struct-tty-term/) (attribute)
- [`tty`](/en/tmux/latest/reference/c-struct-tty/) (struct)
- [`TTYC_ECH`](/en/tmux/latest/reference/c-enum-tty_code_code-ttyc_ech/) (constant)
- [`TTYC_EL`](/en/tmux/latest/reference/c-enum-tty_code_code-ttyc_el/) (constant)
- [`TTYC_EL1`](/en/tmux/latest/reference/c-enum-tty_code_code-ttyc_el1/) (constant)
- [`visible_ranges.used`](/en/tmux/latest/reference/c-struct-visible_ranges-used/) (attribute)
