Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Mouse debouncing
View unanswered posts
View posts from last 24 hours

Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message

Joined: 29 Jul 2017
Posts: 1

PostPosted: Sat Jul 29, 2017 10:26 pm    Post subject: Mouse debouncing Reply with quote

Hope this is the right place to post this...

Sadly I am forced to use a pretty bad mouse since a few that very often registers left clicks as double-clicks. After searching the web a bit I ran into this:

The patches offered there needed some slight adjustment (due to xf86-input-evdev gaining soft scrolling support). But other than move one hunk by three line I didn't really do anything. It seems to work pretty well for me (using it since a few days now) thought I might post it here with the updated patches in case others have a use for it too.

Updated patch for x11-drivers/xf86-input-evdev-2.10.5:

Patch is almost 3000 lines and I am for sure not very versed in x11 a short glance nothing "irregular" jumps at the eye...but yeah...better check yourself, I wouldn't trust me on that. ;)

After putting the patch in /etc/portage/patches/x11-drivers/xf86-input-evdev (might want /etc/portage/patches/x11-drivers/xf86-input-evdev-2.10.5 instead though to have it only applied to this version and not future ones) and rebuilding x11-drivers/xf86-input-evdev it was just following the blog linked above for the config. I have a /etc/X11/xorg.conf.d/05-mouse.conf (not in /usr/share as the blog says) file with this now:

Section "InputClass"
        Identifier "evdev pointer debounce"
        MatchIsPointer "on"
        MatchDriver "evdev"
        Option "DebounceDelay" "20"

For me this works pretty well and gives this old mouse a grace period before it gets trashed. So big thanks to Guntram for the blog and of course to Matt Whitlock for the patch. Maybe useful for someone else too.
Back to top
View user's profile Send private message

Joined: 14 Jun 2007
Posts: 1710
Location: KUUSANKOSKI, Finland

PostPosted: Fri Aug 04, 2017 12:26 pm    Post subject: Reply with quote

I have bouncing issue on one of the total four buttons of my Logitech Marble Trackball.
I might try this. Although choosing a capacitor carefully an placing it in parallel with the switch should solve the issue too. ;) The capacitor based hardware fix can (will) lead to some lag on button unpress.
..: Zucca :..

ERROR: '--failure' is not an option. Aborting...
Back to top
View user's profile Send private message

Joined: 27 Nov 2007
Posts: 39

PostPosted: Mon Sep 04, 2017 5:18 pm    Post subject: Reply with quote

Hi all,

I have a very similar problem with my expensive Logitech G500 since a few weeks. (Before it worked for years without problems.)
However, I'm not absolutely sure if this is the same issue. Could you tell me before I start messing round with patches, if you observed similar behaviour:

First example:
Very often a single left or right click behaves like a double click. I.e. if I right click for a context menu, very often the first entry gets clicked as well, what is very annoying.

Second example:
If I left click on the play button of a music player it directly pauses since it is received as a double click.

Third example:
If I resize a window by holding down the left button on the window edge and move the mouse, after a short distance, the mouse releases the window edge and the resizing stops.
Same behaviour if I select text in a document. After selecting several words or sentences the mouse button releases for a very short time. The previously selected text is not selected anymore and it continues selecting the text after this event.

I don't know which package is responsible for this bug. I don't believe that my mouse button is broken, since it shows the same behaviour for both the left and the right button. The examples above are not related to a specific software. I observed this behaviour in both xfce 4.12 and mate 1.12-r1. I use x11-drivers/xf86-input-mouse-1.9.2 and x11-base/xorg-server-1.19.3.

Help is appreciated. If I can provide further information please let me know.

If it is the same issue and several people experience this, we should reopen this bug-report and file your patch in it (link).
Back to top
View user's profile Send private message

Joined: 08 Aug 2014
Posts: 42
Location: Canadian Prairies

PostPosted: Sun Sep 10, 2017 3:06 pm    Post subject: Reply with quote

I had the "left single click behaves as a double click" problem show up recently. I switched back to KDE Plasma from LxQt not that long ago and I think the problem started sometime after that, but I'm not 100% sure. The problem seems to have shown up around time I switched from linux-4.9.34-gentoo to linux-4.12.5-gentoo, but again I'm not 100% certain. What I do know for sure is that I was able to get rid of the problem by adjusting "Double click interval" in the Advanced tab of System Settings -> Input Devices -> Mouse. The default value was 400msec and I changed it to 300msec.
Back to top
View user's profile Send private message
Ant P.

Joined: 18 Apr 2009
Posts: 6356

PostPosted: Sun Sep 10, 2017 6:56 pm    Post subject: Reply with quote

libinput 1.8.2 has button debouncing built in, fwiw. Won't work in xf86-input-{mouse,evdev} for obvious reasons.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum