diff options
author | Aaron Campbell <aaron@cvs.openbsd.org> | 1999-10-07 02:43:09 +0000 |
---|---|---|
committer | Aaron Campbell <aaron@cvs.openbsd.org> | 1999-10-07 02:43:09 +0000 |
commit | 24081ffd0c00f71c73bf151410dd791176ea48b9 (patch) | |
tree | d9beca075af9ee3e5f66bf115a9cc0a2c094c738 /sys/arch/i386 | |
parent | 63e5f3431e84fef55201922f135e1f528502fc2b (diff) |
Yes, I think I've finally decided how I think scrollback should behave.
Diffstat (limited to 'sys/arch/i386')
-rw-r--r-- | sys/arch/i386/isa/pcvt/pcvt_kbd.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/sys/arch/i386/isa/pcvt/pcvt_kbd.c b/sys/arch/i386/isa/pcvt/pcvt_kbd.c index 095278cc722..5add2e802c5 100644 --- a/sys/arch/i386/isa/pcvt/pcvt_kbd.c +++ b/sys/arch/i386/isa/pcvt/pcvt_kbd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pcvt_kbd.c,v 1.26 1999/10/05 16:38:20 aaron Exp $ */ +/* $OpenBSD: pcvt_kbd.c,v 1.27 1999/10/07 02:43:08 aaron Exp $ */ /* * Copyright (c) 1992, 1995 Hellmuth Michaelis and Joerg Wunsch. @@ -1501,6 +1501,7 @@ regular: vsp->Scrollback, vsp->maxcol * vsp->max_off * CHR); + vsp->scr_offset--; } bcopy(vsp->Crtat + vsp->cur_offset - vsp->col, vsp->Scrollback + @@ -1530,10 +1531,8 @@ scroll_reset: if (vsp->scrolling > 0) { vsp->scrolling -= vsp->screen_rows - 1; - if (vsp->scrolling <= 0) + if (vsp->scrolling < 0) vsp->scrolling = 0; - else if (vsp->scrolling < vsp->screen_rows) - vsp->scrolling = vsp->screen_rows - 1; if (vsp->scrolling <= vsp->row) { @@ -1542,10 +1541,16 @@ scroll_reset: } else { + if (vsp->scrolling + 2 < vsp->screen_rows) + fillw(user_attr | ' ', + (caddr_t)vsp->Crtat, + vsp->screen_rows * vsp->maxcol); + bcopy(vsp->Scrollback + ((vsp->scr_offset - vsp->scrolling) * vsp->maxcol), - vsp->Crtat, vsp->screen_rows * - vsp->maxcol * CHR); + vsp->Crtat, (vsp->scrolling + 2 < + vsp->screen_rows ? vsp->scrolling + 2 : + vsp->screen_rows) * vsp->maxcol * CHR); } } |