en.opensuse.org

Keys and mouse

This is about the keys and mouse configuration under Linux and how I have done it. There are several ways to do things and I might adapt how I do things in the future.

The keys:
I have a Happy Hacker keyboard. This means that I do not have a CAPS-LOCK key. I can press Fn-TAB to get the same results. However I have no use for a CAPS-LOCK key, so I wanted to use it as a compose key so I can type strange characters.
Add the following line to the Keybord part in xorg.conf

Option          "XkbOptions"    "compose:caps"

The mouse:
I have a multi button mouse. These are the settings and wanted settings:

Button
Default
Wanted
1 Left click Left click
2 Middle click Unused
3 Right click Right click
4 Scroll up Scroll up
5 Scroll down Scroll Down
6 Scroll Left Workspace up
7 Scroll Right Workspace down
8 Forward Sound up
9 Back Sound down
10 Unused Middle click

So first the switching of keys 2 and 10. This is done by simply doing the following:

xmodmap -e "pointer = 1 10 3 4 5 6 7 8 9 2"
A nice way to confuse peoples mouse behaviour by inverting scroll direction is possible that way. To get to know what key is what, launch the following and press each key which will show what button nummer is pressed. Don't forget to scroll.
xev|grep button
The reason for this change of button 2 and 10 is because otherwise pressing the scrollbutton will cause change of workspace, because it is so sensitive. The downside is that Firefox does not acknowledge the diferent usage I will give to it. Stoopid Firefox.

To get different usage for the buttons I first looked what the shortcuts where that I needed. I then installed btnx-config and ran that as root. Lat but not least I saw to it that btnx-config started when init 5 starts and the xmodmap when I log in as user.