From dbe4c7712b652b7ad3126e94c47b00fa2bbb0a05 Mon Sep 17 00:00:00 2001 From: Marcus Brinkmann Date: Tue, 17 Sep 2002 11:47:15 +0000 Subject: 2002-09-16 Marcus Brinkmann * cons.h: Add prototype for cons_vcons_clear. * file-changed.c (cons_S_file_changed): Prepare all areas we write to with cons_vcons_clear (unless we use cons_vcons_scroll already). * vcons-refresh.c (cons_vcons_refresh): Likewise. * vcons-scrollback.c (_cons_vcons_scrollback): Likewise. --- libcons/file-changed.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'libcons/file-changed.c') diff --git a/libcons/file-changed.c b/libcons/file-changed.c index 7b78a317..f65eb0b5 100644 --- a/libcons/file-changed.c +++ b/libcons/file-changed.c @@ -162,6 +162,10 @@ cons_S_file_changed (cons_notify_t notify, natural_t tickno, scrolling = vcons->state.screen.height; if (scrolling < vcons->state.screen.height) cons_vcons_scroll (vcons, scrolling); + else + cons_vcons_clear (vcons, vcons->state.screen.width + * vcons->state.screen.height, + 0, 0); vis_start = vcons->state.screen.width * (cur_disp_line % vcons->state.screen.lines); start = (((cur_disp_line % vcons->state.screen.lines) @@ -299,6 +303,9 @@ cons_S_file_changed (cons_notify_t notify, natural_t tickno, if (start != -1) { + cons_vcons_clear (vcons, end - start + 1, + start_rel % vcons->state.screen.width, + start_rel / vcons->state.screen.width); cons_vcons_write (vcons, vcons->state.screen.matrix + start, end < size ? end - start + 1 @@ -314,6 +321,7 @@ cons_S_file_changed (cons_notify_t notify, natural_t tickno, / vcons->state.screen.width); if (end2 != -1) { + cons_vcons_clear (vcons, end2 - rotate + 1, 0, 0); cons_vcons_write (vcons, vcons->state.screen.matrix + rotate, end2 < size -- cgit v1.2.3