Adds system-wide:
Can be used by mouse or graphics tablet users.
Scrolling mode requires selected button to be unbound (example).
Since 0.3.0, keyboard shortcuts are not captured correctly. So if you want to e.g. bind LMB to Z, and open link in a new tab by pressing Ctrl+Z (Ctrl+LMB), unbind Ctrl+Z in your browser settings beforehand.
```toml
button_id
to start scrolling,[scroll]
xinput list
and xinput test-xi2 --root
todevice = "Wacom Bamboo Pen stylus"
subdevice = 0
hold = false
means click once to enable, click once to disable.false
on tablets, as it's annoying when you connectivityhold = true
.hold = false
speed
to high value and decrease system-widespeed
×distance
[px]speed = 600000
button_id = 3
timeout_ms
has passed since[keyboard_click]
xinput list
and xinput test-xi2 --root
to determine.device = "Wacom Bamboo Pen stylus"
subdevice = 0
timeout_ms = 500
key_lmb = 52 # Z
key_rmb = 53 # X
key_unused1 = 106 # numpad /
key_unused2 = 63 # numpad * ```
Use config above, but replace xinput_grep
with f.e. "Gaming Mouse", and stylus_button_id
with some button ID. Middle button ID is 2, but that requires you to unbind its pasting functionality somehow. I recommend using additional buttons if your mouse has these. Button IDs 4 and 5 are reserved for scroll events. You can check button IDs with xinput test-xi2 --root
.
First, install xdotool
and xmodmap
.
Grab binary from Releases page, or build it yourself by copying the source and running cargo build --release
, or have Cargo download the sources and put binary in PATH
for you with cargo install x11-input-supercharger
. Rust stable toolchain is required.
Config.toml
must be in current working directory when starting the program.
Konsole (terminal emulator) doesn't like having a key pressed when selecting. Use Gnome Terminal.
The program grabs root X11 input device.
The code is ugly, and the program sometimes crashes on shutdown (but doesn't seem to leave the system in broken state).
KSysGuard shows the program uses 0-1% of CPU time on Intel i5 6300HQ.
If the program is unstable on your system, check out versions 0.2.x. They used text parser instead of X11 API. However, different keyboard grabbing solution was used back then, which caused lags in Chromium-based programs. See older tree for old README.
Thanks to Bruce Byfield for his Wacom-related articles for Linux Magazine.
Thanks to Linux Wacom Project developers for making it possible to use Wacom as input device on Linux.
Thanks to all X11 developers for awesome tools they created.