Graphics Administration Guide (July 2008)

Table Of Contents
changing mouse button actions
The xmodmap utility can be used to change mouse button mappings. The syntax for
changing mouse button mappings with xmodmap is:
xmodmap {-e “pointer = {default | number [number...]}” | -pp}
where:
-e
Specifies a remapping expression.
default
Set mouse keys back to default bindings.
number
Specifies a list of button numbers to map the mouse keys to. The order of the numbers
refers to the original button mapping.
pp
Print the current pointer mapping.
For example, to reverse the positions of buttons 1 and 3 for left-handed mapping:
xmodmap -e “pointer = 3 2 1" (2-button mouse)
modifying modifier key bindings with xmodmap
To change the meaning of a particular key for a particular X11 session, or to initialize
the X Server with a completely different set of key mappings, use the xmodmap client.
The syntax for xmodmap is as follows: xmodmap <options> [<filename>] where
<options> are:
-display <host>:<display>
Specifies the host, display number, and screen to use.
-help
Displays a brief description of xmodmap options.
-grammar
Displays a brief description of the syntax for modification expressions.
-verbose
Prints log information as xmodmap executes.
-quiet
Turns off verbose logging. This is the default.
-n
Lists changes to key mappings without actually making those changes.
-e <expression>
50 X Server configuration details