Search the FAQ Archives

3 - A - B - C - D - E - F - G - H - I - J - K - L - M
N - O - P - Q - R - S - T - U - V - W - X - Y - Z
faqs.org - Internet FAQ Archives

comp.windows.x Frequently Asked Questions (FAQ) 2/7
Section - 36)! How can I control the mouse with the keyboard?

( Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Single Page )
[ Usenet FAQs | Web FAQs | Documents | RFC Index | Schools ]


Top Document: comp.windows.x Frequently Asked Questions (FAQ) 2/7
Previous Document: 35) Why are my xterm menus so small (sic) ?
Next Document: 37) How can I print the current X selection?
See reader questions & answers on this topic! - Help others by sharing your knowledge

If you have the X Keyboard (XKB) Extension, you can enable mouse keys, which
makes it possible to generate mouse motion and button events using the
keyboard.   Events generated by MouseKeys are completely transparent -- they
will work with any application that connects to a server that has the X
Keyboard Extension, regardless of whether the application itself uses XKB.

XKB is enabled by default in X11R6.1.  

First, set up the Num Lock key so that Shift+Num_Lock toggles mouse keys:

 xmodmap -e "keysym Num_lock = Num_Lock Pointer_EnableKeys"

(XFree86 3.1.2E is based on R6.1 and has the X Keyboard Extension; it also
has a binding to Pointer_EnableKeys in its default keymap.  You use
Alt+Shift+Num_Lock to toggle MouseKeys on and off.  If you are using an
earlier release of X or XFree86, you won't have XKB and the instructions will
not work. See http://www.XFree86.org/FAQ for more information.)

You might also have to turn off server num lock for this to work.  
Now press "Shift+Num_Lock" to enable MouseKeys.  When MouseKeys are on:

o)   The keypad arrow keys move the pointer
o)   The keypad '5' key behaves like the 'default' pointer button
o)   The keypad '0' key locks the default pointer button (for easy dragging)
o)   The keypad '.' key unlock the default pointer button (to release a drag)
o)   The keypad '+' key double-clicks the default pointer button.
o)   The keypad '/' key sets the 'default' button to Button1
o)   The keypad '*' key sets the default button to Button2
o)   The keypad '-' key sets the default button to Button3

This is the default configuration, but the mechanism allows for nearly
infinite configurability.

[thanks to Erik Fortune (erik@westworld.engr.sgi.com), 6/96]

User Contributions:

Comment about this article, ask questions, or add new information about this topic:




Top Document: comp.windows.x Frequently Asked Questions (FAQ) 2/7
Previous Document: 35) Why are my xterm menus so small (sic) ?
Next Document: 37) How can I print the current X selection?

Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Single Page

[ Usenet FAQs | Web FAQs | Documents | RFC Index ]

Send corrections/additions to the FAQ Maintainer:
faq%craft@uunet.uu.net (X FAQ maintenance address)





Last Update March 27 2014 @ 02:12 PM