Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

held-autoscroll

Wayland-only, desktop-agnostic middle-button-held autoscroll for one relative mouse. The program forwards selected physical mice through virtual mice, suppresses their middle buttons, and sends wheel events while the middle button is held.

The virtual mouse preserves the selected mouse's kernel ID and name so libinput can apply the same hardware database settings (including DPI) rather than treating it as a generic pointer.

Middle clicks are delayed until release: a press-and-release inside the dead zone is forwarded as a normal middle click, while dragging beyond the dead zone starts autoscroll and consumes the middle button.

make
# Start one worker for every udev-classified mouse connected at launch:
./held-autoscroll
# Limit it to one specific mouse:
./held-autoscroll --device /dev/input/by-id/<your-mouse>-event-mouse

The account needs read access to every /dev/input/event* mouse (or the one passed through --device) and write access to /dev/uinput; set those permissions with narrowly scoped udev/group rules appropriate for the system. These permissions are security-sensitive.

Tuning is command-line only:

--dead-zone-counts N          default: 8
--rate N                      detents/s/count², default: 0.005
--max-detents-per-second N    default: 100

Run make test without touching input devices. No cursor appearance is changed, and no X11 support, GUI, service, or desktop-specific integration is included. Automatic discovery scans only at startup; newly connected mice require restarting it.

About

Middle-mouse-held autoscroll for Wayland desktops

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages