oneko icon indicating copy to clipboard operation
oneko copied to clipboard

Make Oneko Click-through

Open jyi2ya opened this issue 3 years ago • 2 comments

With a window manager that uses the "Focus Follows Mouse" mode, oneko is focused every time it reaches the mouse. If focused, oneko will consume all mouse events, which is sometimes annoying. For example, if I click a button and oneko is laying under the mouse, this click event will be sent to oneko but not the button. I have to first move the mouse to somewhere to drive away oneko, and try to click the button before it comes back.

This patch tries to solve this problem by making oneko click-through. All events that oneko received will be simply passed through. This feature depends on X11 XFixed extension, which means we need to add -lXfixed to our compile options.

jyi2ya avatar Jan 10 '23 05:01 jyi2ya

oo! thanks so much, I like this and want to accept it. I will do detailed code review when I get the chance, it may be a little while.

IreneKnapp avatar Mar 10 '23 00:03 IreneKnapp

You don't need enabling XFixes extension for such basic shape usage. A following call would suffice.

XShapeCombineRectangles(theDisplay, theWindow, ShapeInput, 0, 0, NULL, 0, ShapeSet, YXBanded);

Which roughly translates to: set ShapeInput to be an empty set of rectangles, i.e. a completely empty shape.

xzfc avatar Mar 14 '25 13:03 xzfc