aboutsummaryrefslogtreecommitdiff
path: root/terminal.c
diff options
context:
space:
mode:
Diffstat (limited to 'terminal.c')
-rw-r--r--terminal.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/terminal.c b/terminal.c
index b9d2f0f3..95a60682 100644
--- a/terminal.c
+++ b/terminal.c
@@ -363,6 +363,16 @@ term_reverse_index(struct terminal *term)
}
void
+term_reset_view(struct terminal *term)
+{
+ if (term->grid->view == term->grid->offset)
+ return;
+
+ term->grid->view = term->grid->offset;
+ term_damage_view(term);
+}
+
+void
term_restore_cursor(struct terminal *term)
{
int row = min(term->saved_cursor.row, term->rows - 1);