aboutsummaryrefslogtreecommitdiff
path: root/terminal.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2020-02-21 23:05:25 +0000
committerDaniel Eklöf <daniel@ekloef.se>2020-02-21 23:05:25 +0000
commit63140a68f516c8b4616bf6c726d23a75b73e5713 (patch)
tree2bf9158f18f83569c3f5fe0da57ad8afa2001901 /terminal.c
parentrender: break out sixel rendering code (diff)
sixel: calculate image height in (cell) rows
Diffstat (limited to 'terminal.c')
-rw-r--r--terminal.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/terminal.c b/terminal.c
index b80b9898..c6c349c3 100644
--- a/terminal.c
+++ b/terminal.c
@@ -1601,8 +1601,7 @@ term_scroll_reverse_partial(struct terminal *term,
/* TODO: untested */
- int img_rows = (it->item.height + term->cell_height - 1) / term->cell_height;
- int img_bottom_row = (it->item.pos.row + img_rows) & (term->grid->num_rows - 1);
+ int img_bottom_row = (it->item.pos.row + it->item.rows) & (term->grid->num_rows - 1);
int new_row = (term->grid->offset + r) & (term->grid->num_rows - 1);
if (img_bottom_row == new_row) {