diff options
author | Marcus Brinkmann <marcus@gnu.org> | 2002-08-28 17:28:36 +0000 |
---|---|---|
committer | Marcus Brinkmann <marcus@gnu.org> | 2002-08-28 17:28:36 +0000 |
commit | 513afcf4f8cd67275bad59251d1ee2a845d0ddca (patch) | |
tree | 50ba58bd26fca25385be71fb144daadc287063b9 /libcons/vcons-refresh.c | |
parent | d14e2936fd203532ed19471c504b5b43adecf74b (diff) |
hurd/
2002-08-28 Marcus Brinkmann <marcus@gnu.org>
* console.h (struct cons_display): Fix comment on CUR_LINE.
console/
2002-08-28 Marcus Brinkmann <marcus@gnu.org>
* display.c (screen_fill): Take CUR_LINES modulo LINES.
(screen_shift_left): Likewise.
(screen_shift_right): Likewise.
(linefeed): Don't take CUR_LINES modulo LINES here.
libcons/
2002-08-28 Marcus Brinkmann <marcus@gnu.org>
* file-changed.c (cons_S_file_changed): Take NEW_CUR_LINE modulo
VCONS->state.screen.lines where appropriate. Adapt calculation of
SCROLLING, and limit it to the screen size.
Only scroll at all if there is something to scroll.
Fix calculation of scrolled-in area.
* vcons-refresh.c (cons_vcons_refresh): Take
VCONS->state.screen.cur_line modulo VCONS->state.screen.lines.
Diffstat (limited to 'libcons/vcons-refresh.c')
-rw-r--r-- | libcons/vcons-refresh.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/libcons/vcons-refresh.c b/libcons/vcons-refresh.c index 34f0de88..35e74224 100644 --- a/libcons/vcons-refresh.c +++ b/libcons/vcons-refresh.c @@ -37,21 +37,25 @@ cons_vcons_refresh (vcons_t vcons) vcons->state.changes.written = vcons->display->changes.written; cons_vcons_write (vcons, vcons->state.screen.matrix - + vcons->state.screen.cur_line * vcons->state.screen.width, - ((vcons->state.screen.lines - vcons->state.screen.cur_line + + (vcons->state.screen.cur_line % vcons->state.screen.lines) + * vcons->state.screen.width, + ((vcons->state.screen.lines + - (vcons->state.screen.cur_line % vcons->state.screen.lines) < vcons->state.screen.height) - ? vcons->state.screen.lines - vcons->state.screen.cur_line + ? vcons->state.screen.lines + - (vcons->state.screen.cur_line % vcons->state.screen.lines) : vcons->state.screen.height) * vcons->state.screen.width, 0, 0); - if (vcons->state.screen.lines - vcons->state.screen.cur_line + if (vcons->state.screen.lines + - (vcons->state.screen.cur_line % vcons->state.screen.lines) < vcons->state.screen.height) cons_vcons_write (vcons, vcons->state.screen.matrix, vcons->state.screen.height * vcons->state.screen.width - (vcons->state.screen.lines - - vcons->state.screen.cur_line) + - (vcons->state.screen.cur_line % vcons->state.screen.lines)) * vcons->state.screen.width, 0, vcons->state.screen.lines - - vcons->state.screen.cur_line); + - (vcons->state.screen.cur_line % vcons->state.screen.lines)); cons_vcons_set_cursor_pos (vcons, vcons->state.cursor.col, vcons->state.cursor.row); |