aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJesse Luehrs <doy@tozt.net>2014-04-22 01:51:22 -0400
committerJesse Luehrs <doy@tozt.net>2014-04-22 01:52:50 -0400
commitf510d8dbce9f902d8ef795a5e3df8174b6921bbd (patch)
treecab2522b5bfdac56563d7911764d7c2cc469438d
parent864caa2f02053234012af0214cc49803e539f7eb (diff)
downloadrunes-f510d8dbce9f902d8ef795a5e3df8174b6921bbd.tar.gz
runes-f510d8dbce9f902d8ef795a5e3df8174b6921bbd.zip
this should really be using scroll_bottom
i can't seem to find an app where this makes a difference for, they seem to go out of their way to avoid using IL/DL if scroll_bottom isn't at the bottom of the terminal - i'm guessing terminals have been buggy about this in the past.
-rw-r--r--src/display.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/display.c b/src/display.c
index 0b57c3c..dd41344 100644
--- a/src/display.c
+++ b/src/display.c
@@ -241,7 +241,7 @@ void runes_display_insert_lines(RunesTerm *t, int count)
cairo_pattern_set_matrix(pattern, &matrix);
runes_display_paint_rectangle(
t, t->cr, pattern,
- 0, t->row + count, t->cols, t->rows - t->row - count);
+ 0, t->row + count, t->cols, t->scroll_bottom + 1 - t->row - count);
cairo_pattern_destroy(pattern);
cairo_pop_group_to_source(t->cr);
cairo_paint(t->cr);
@@ -282,12 +282,14 @@ void runes_display_delete_lines(RunesTerm *t, int count)
cairo_matrix_init_translate(&matrix, 0.0, count * t->fonty);
cairo_pattern_set_matrix(pattern, &matrix);
runes_display_paint_rectangle(
- t, t->cr, pattern, 0, t->row, t->cols, t->rows - t->row - count);
+ t, t->cr, pattern,
+ 0, t->row, t->cols, t->scroll_bottom + 1 - t->row - count);
cairo_pattern_destroy(pattern);
cairo_pop_group_to_source(t->cr);
cairo_paint(t->cr);
runes_display_paint_rectangle(
- t, t->cr, t->bgdefault, 0, t->rows - count, t->cols, count);
+ t, t->cr, t->bgdefault,
+ 0, t->scroll_bottom + 1 - count, t->cols, count);
cairo_restore(t->cr);
}