Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back > Linux Answers > Hardware
User Name


By billy rauter at 2008-10-16 23:58
Hello all!

I wanted to use imwheel with my ancient logitech corded and balled four button mouse. The searches did not come up with anything conclusive but with some bits here and tweaking there I got it to work and am posting this in case someone might find it useful. Remember that this is what worked for me; it might not do so for you. A page that came close to providing a working solution was . My mouse needed a slightly different setup though, so some adjustments were necessary.

The main objective was to make command kommand in kde 3 to work from the middle button and to have the K menu on the thumb of the mouse. I'll walk you through this and then you can modify the procedure to do what you want.

Install imwheel, xmodmap and kommand, if you haven't done so.
Launch kommand from the command line and set it's shortcut to ctrl+menu, or whatever.

Now let’s get that rodent section xorg.conf right, this works on my system:

Section "InputDevice"
    Identifier     "Configured Mouse"
    Driver         "mouse"
    Option         "CorePointer"
    Option         "Device" "/dev/input/mice"
    Option         "Protocol" "ExplorerPS/2"
    Option         "Buttons" "6"
    Option         "ZAxisMapping" "4 5"
    Option         "ButtonMapping" "1 2 3 6"
    Option         "Resolution" "100"
    Option         "Emulate3Buttons" "true"
And, the imwheelrc:

None, Up, Control_L|Menu

None, Up, Control_L|Menu
After that we just need a simple startup script or something, like this in ~/.kde/Autostart. We’ll adjust the button sequence with xmodmap to flip the middle and thumb buttons. Remember to make the file executable.

#! /bin/sh

/usr/bin/xmodmap -e "pointer = 1 6 3 4 5 2" &
/usr/bin/imwheel -k -b "6" &
You might want to put kommand in there too, pending your sessions configuration.

That should be it. I'm sure that there might be cooler ways to do this...


All times are GMT -5. The time now is 07:53 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration