From 59d2c9b65f90f78507b88d773323aab31194b7b4 Mon Sep 17 00:00:00 2001 From: Dennis Lee Date: Mon, 29 Jun 2020 21:33:08 -0700 Subject: [PATCH] universcroll: sane default configuration - Set scroll program = "scroll" - Mouse wheel scroll only with NO_MOD. - Mouse wheel zoom with ShiftMask/ANY_MOD. --- config.def.h | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/config.def.h b/config.def.h index a52c0a2..74fd64c 100644 --- a/config.def.h +++ b/config.def.h @@ -19,7 +19,7 @@ static int borderpx = 2; static char *shell = "/bin/sh"; char *utmp = NULL; /* scroll program: to enable use a string like "scroll" */ -char *scroll = NULL; +char *scroll = "scroll"; char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400"; /* identification sequence returned in DA and DECID */ @@ -175,10 +175,14 @@ static uint forcemousemod = ShiftMask; static MouseShortcut mshortcuts[] = { /* mask button function argument release alt */ { XK_ANY_MOD, Button2, selpaste, {.i = 0}, 1 }, - { XK_ANY_MOD, Button4, ttysend, {.s = "\033[5;2~"}, 0, -1 }, - { XK_ANY_MOD, Button4, ttysend, {.s = "\031"} }, - { XK_ANY_MOD, Button5, ttysend, {.s = "\033[6;2~"}, 0, -1 }, - { XK_ANY_MOD, Button5, ttysend, {.s = "\005"} }, + { ShiftMask, Button4, zoom, {.f = +1} }, + { ShiftMask, Button5, zoom, {.f = -1} }, + { XK_NO_MOD, Button4, ttysend, {.s = "\033[5;2~"}, 0, -1 }, + { XK_NO_MOD, Button4, ttysend, {.s = "\031"} }, + { XK_NO_MOD, Button5, ttysend, {.s = "\033[6;2~"}, 0, -1 }, + { XK_NO_MOD, Button5, ttysend, {.s = "\005"} }, + { XK_ANY_MOD, Button4, zoom, {.f = +1} }, + { XK_ANY_MOD, Button5, zoom, {.f = -1} }, }; /* Internal keyboard shortcuts. */ -- 2.27.0