[xmonad] New virtual X mouse tool
Blake Miller
blak3mill3r at gmail.com
Mon Dec 31 03:07:35 UTC 2018
This is only indirectly related to XMonad...
For a while I've been using keynav to avoid reaching for the mouse for
those few annoying circumstances which seemingly require a mouse.
I did find that keynav sometimes saved me some energy, but I only found it
useful for simple clicks. It does not seem useful if you want to click and
drag a region, for example.
Repeatedly bisecting the screen to narrow in on a point for the cursor is a
fine approach and has some advantages, but I found myself wanting something
more visceral: a little physics simulation to let me move the mouse around
using the keyboard, like a video game.
So I put this little utility together, in C++, and I have a keybinding
spawn it from xmonad.
It was an interesting challenge to make it single-threaded and still
simultaneously run the physics loop, poll for X events, and send fake mouse
events with XTest. I ended up designing it around channels (as in CSP)
using boost::fiber.
I hope someone finds it useful or entertaining! I had fun writing it.
https://github.com/blak3mill3r/mouser
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/xmonad/attachments/20181231/ff531573/attachment.html>
More information about the xmonad
mailing list