[hackers] [scroll] Fix cursor position in scrollup || Jochen Sprickerhof

From: <git_AT_suckless.org>
Date: Sat, 25 Apr 2020 23:32:24 +0200 (CEST)

commit 2f696500f791925b6d5cdff3268e57f2fbc3a2a9
Author: Jochen Sprickerhof <git_AT_jochen.sprickerhof.de>
AuthorDate: Sat Apr 25 23:32:04 2020 +0200
Commit: Jochen Sprickerhof <git_AT_jochen.sprickerhof.de>
CommitDate: Sat Apr 25 23:32:04 2020 +0200

    Fix cursor position in scrollup

diff --git a/scroll.c b/scroll.c
index 9ff5398..652eba9 100644
--- a/scroll.c
+++ b/scroll.c
_AT_@ -340,7 +340,7 @@ scrollup(int n)
         }
         /* move cursor from line n to the old bottom position */
         if (y + n < ws.ws_row) {
- dprintf(STDOUT_FILENO, "\033[%d;%dH", y + n, y);
+ dprintf(STDOUT_FILENO, "\033[%d;%dH", y + n, x);
                 write(STDOUT_FILENO, "\033[?25h", 6); /* show cursor */
         } else
                 dprintf(STDOUT_FILENO, "\033[%d;0H", ws.ws_row);
Received on Sat Apr 25 2020 - 23:32:24 CEST

This archive was generated by hypermail 2.3.0 : Sat Apr 25 2020 - 23:36:42 CEST