scrolling: add scrolling with mouse

This commit is contained in:
TiynGER 2021-05-24 16:25:13 +02:00
parent c3f33944b8
commit 893f132e40
2 changed files with 20 additions and 14 deletions

View File

@ -1,6 +1,8 @@
# st # st
This is my patched version of st. The base version is directly from suckless.org. This is my patched version of st. The base version is directly from suckless.org.
This belongs to my larbs installation script, but does not directly depend on it.
It is supposed to work in the environment after the larbs-base-installation.
## Patches ## Patches
@ -16,7 +18,7 @@ The list below shows the currently applied patches to the master branch.
There are various shortcuts and hotkeys used in this version. Included in my build are the following. There are various shortcuts and hotkeys used in this version. Included in my build are the following.
| ModKey | Shift | Key | Function | | ModKey | Shift | Key | Function |
|--------|-------|---------|-----------------| | ------ | ----- | --------------- | --------------- |
| Alt | | Break | Send break | | Alt | | Break | Send break |
| Alt | | Print | Toggle printer | | Alt | | Print | Toggle printer |
| Alt | | Print | Print screen | | Alt | | Print | Print screen |
@ -27,6 +29,8 @@ There are various shortcuts and hotkeys used in this version. Included in my bui
| Alt | | NumLock | Toggle Numlock | | Alt | | NumLock | Toggle Numlock |
| Alt | | k | Scroll up | | Alt | | k | Scroll up |
| Alt | | j | Scroll down | | Alt | | j | Scroll down |
| | | MouseScrollUp | Scroll up |
| | | MouseScrollDown | Scroll down |
| Alt | Shift | u | Zoom in | | Alt | Shift | u | Zoom in |
| Alt | Shift | i | Zoom out | | Alt | Shift | i | Zoom out |

View File

@ -170,6 +170,8 @@ static MouseShortcut mshortcuts[] = {
/* mask button function argument release */ /* mask button function argument release */
{ Button4, XK_NO_MOD, "\031" }, { Button4, XK_NO_MOD, "\031" },
{ Button5, XK_NO_MOD, "\005" }, { Button5, XK_NO_MOD, "\005" },
{ XK_NO_MOD, Button4, kscrollup, {.i = 1} },
{ XK_NO_MOD, Button5, kscrolldown,{.i = 1} },
}; };
/* Internal keyboard shortcuts. */ /* Internal keyboard shortcuts. */