st

[fork] terminal
Log | Files | Refs | README | LICENSE

commit f8446ca814731b79e1db9d5aa3897f65bee844c6
parent 6cd9971fc2d225d23e21dfe69f44c3a90977cc99
Author: hhvn <hayden@haydenvh.com>
Date:   Thu, 28 Jan 2021 21:04:57 +0000

st.c: scroll only by half height

Diffstat:
Mst.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/st.c b/st.c @@ -1066,10 +1066,10 @@ kscrolldown(const Arg* a) int n = a->i; if (n < 0) - n = term.row + n; + n = (term.row / 2) + n; if (n > term.scr) - n = term.scr; + n = (term.scr / 2); if (term.scr > 0) { term.scr -= n; @@ -1104,7 +1104,7 @@ kscrollup(const Arg* a) int n = a->i; if (n < 0) - n = term.row + n; + n = (term.row / 2) + n; if (term.scr <= HISTSIZE-n) { term.scr += n;