r/archlinux • • 20h ago

SHARE xhidecursor finally maintained in the AUR

Hey guys! I am the maintainer of xhidecursor, a minimal (fr) X11 utility that efficiently (nocap) hides the cursor on key presses and shows it again on mouse movement. Just wanted to announce that I’ve taken over and updated the AUR package, which had been orphaned and out of date for a while.

I wrote xhidecursor because xbanish (a popular alternative) couldn’t satisfy my OCD for minimalism. xhidecursor prioritizes a simple implementation and efficient event processing, ignoring redundant input events.

Let me know if there are any issues and if it runs as expected on your system. Thank you!

6 Upvotes

7 comments sorted by

4

u/C0rn3j 20h ago

efficient event processing, ignoring redundant input events

And you couldn't contribute that to the existing tool why?

8

u/blimpin_aint_easy 18h ago

I don't think its very easy to "add minimalism" to an existing project. Going from 488 lines of code to 72 is a full rewrite, even if functionality were identical.

-5

u/C0rn3j 15h ago

I didn't say anything about minimalism.

3

u/blimpin_aint_easy 15h ago

You didn't, OP did, my point is that the reason that they didn't contribute to the existing tool was that their goals were not achievable with a simple contribution to the existing tool.

2

u/aleksandrsstier 14h ago edited 14h ago

At the time I originally wrote xhidecursor, my primary goal was to make my system as minimal as possible, even if that meant rewriting some programs. Fixing the event processing in xbanish wouldn’t give me the small codebase I wanted.

That’s the same reason I stripped down and rewrote dwm into my own window manager with 500 lines of code. I could have made dwm behave how I wanted, but it still had thousands of lines of code I didn’t need.

These are tools I wrote for myself to satisfy my personal preference for minimalism and focused functionality. I used them for a long time before deciding to publish them in case somebody else had the same preferences.

Maybe you meant that beside writing xhidecursor I also could have fixed xbanish. I could but I was already overwhelmed by all the other mess I tried to fix on my system and xhidecursor already did everything I needed. Now that people know the issue maybe somebody will take some time to fix xbanish.

1

u/OneTurnMore 17h ago

The most common X11 utility I've seen historically was unclutter, it's in the main repos and I used it on i3 for years. I'm curious how it benchmarks in your case, since it's also based on xfixes.

It definitely wouldn't satisfy your desire for minimalism though, with its timeout, jitter, and ignored-button options. Nice to see a tiny implementation of the most common path!

2

u/aleksandrsstier 14h ago

I know about unclutter and the other alternatives like xbanish. The benchmark results would, I assume, depend largely on how unclutter handles input events.

It seems that unclutter’s current development version keeps processing input events even when they don’t change cursor visibility. That serves a purpose when resetting its idle timeout, but still happens with --hide-on-key-press --no-timeout, which is the mode closest to how xhidecursor works. That’s one of the issues xhidecursor specifically tries to solve. xhidecursor changes its event subscriptions when visibility changes, avoiding those redundant events.

Regarding the other features you mentioned. These are all things I don’t need, and xhidecursor does exactly what I want it to do and nothing more. I initially wrote this tool primarily for myself and had been using it for a long time before I published it. Thats how it came to be.