# grid_scroll_history

- **Language:** C
- **Kind:** function
- **Source:** https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/grid.c#L432
- **Page:** https://libtmux.org/en/tmux/3.7c/reference/c-function-grid_scroll_history/

```c
void grid_scroll_history(struct grid *gd, u_int bg)
```

## Parameters

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

## Called by

- [`grid_view_clear_history`](/en/tmux/3.7c/reference/c-function-grid_view_clear_history/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/grid-view.c#L86)
- [`grid_view_scroll_region_up`](/en/tmux/3.7c/reference/c-function-grid_view_scroll_region_up/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/grid-view.c#L112)

## Calls

- [`grid_compact_line`](/en/tmux/3.7c/reference/c-function-grid-c-grid_compact_line/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/grid.c#L442)
- [`grid_empty_line`](/en/tmux/3.7c/reference/c-function-grid_empty_line/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/grid.c#L439)
- [`xreallocarray`](/en/tmux/3.7c/reference/c-function-xreallocarray/) (function) [Call site](https://github.com/tmux/tmux/blob/e476c1230b958df0cb12977517d24b3dc931375b/grid.c#L437)

## Referenced declarations

- [`grid_cell.bg`](/en/tmux/3.7c/reference/c-struct-grid_cell-bg/) (attribute)
- [`current_time`](/en/tmux/3.7c/reference/c-variable-current_time/) (attribute)
- [`grid`](/en/tmux/3.7c/reference/c-struct-grid/) (struct)
- [`grid.hscrolled`](/en/tmux/3.7c/reference/c-struct-grid-hscrolled/) (attribute)
- [`grid.hsize`](/en/tmux/3.7c/reference/c-struct-grid-hsize/) (attribute)
- [`grid.linedata`](/en/tmux/3.7c/reference/c-struct-grid-linedata/) (attribute)
- [`grid.sy`](/en/tmux/3.7c/reference/c-struct-grid-sy/) (attribute)
- [`grid_line.time`](/en/tmux/3.7c/reference/c-struct-grid_line-time/) (attribute)
