From 7421a0b9e380c58fab6bd12ba86b58538847d6a8 Mon Sep 17 00:00:00 2001 From: Luflosi Date: Mon, 14 Jan 2019 00:07:17 +0100 Subject: [PATCH] Apply negative scroll multiplier in alternate screen mode Fixes kovidgoyal/kitty#1299 --- kitty/mouse.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kitty/mouse.c b/kitty/mouse.c index c37db8b84..ee218ecc5 100644 --- a/kitty/mouse.c +++ b/kitty/mouse.c @@ -615,6 +615,8 @@ scroll_event(double UNUSED xoffset, double yoffset, int flags) { // Only use wheel_scroll_multiplier if we are scrolling kitty scrollback or in mouse // tracking mode, where the application is responsible for interpreting scroll events yoffset *= OPT(wheel_scroll_multiplier); + } else if (OPT(wheel_scroll_multiplier) < 0) { + yoffset *= -1; } s = (int) round(yoffset); // apparently on cocoa some mice generate really small yoffset values