mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
csi: re-set cursor when switching between alt and normal screen
This forces a refresh of the "current line" pointer.
This commit is contained in:
parent
cc2931007c
commit
8ed7239458
1 changed files with 4 additions and 0 deletions
4
csi.c
4
csi.c
|
|
@ -587,6 +587,8 @@ csi_dispatch(struct terminal *term, uint8_t final)
|
|||
term->grid = &term->alt;
|
||||
term->saved_cursor = term->cursor;
|
||||
|
||||
term_cursor_to(term, term->cursor.row, term->cursor.col);
|
||||
|
||||
tll_free(term->alt.damage);
|
||||
tll_free(term->alt.scroll_damage);
|
||||
term_erase(term, 0, term->rows * term->cols);
|
||||
|
|
@ -644,6 +646,8 @@ csi_dispatch(struct terminal *term, uint8_t final)
|
|||
|
||||
term->cursor = term->saved_cursor;
|
||||
|
||||
term_cursor_to(term, term->cursor.row, term->cursor.col);
|
||||
|
||||
/* Should these be restored from saved values? */
|
||||
term->scroll_region.start = 0;
|
||||
term->scroll_region.end = term->rows;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue