Adding Keyboard Shortcuts
The bare-bones system.fvwmrc file that we started with offers little in the way of keyboard shortcuts, or accelerators, for window management functions. But if you’re one of those users who prefers to keep her hands on the keyboard and off the mouse as much as possible, within your .fvwm2rc file you can easily define keys to perform a variety of functions.
Keyboard Shortcuts to Navigate the Desktop
The Pager is a great tool for getting around one or more desktops. But many people hate using the mouse. You can configure a bunch of keys to let you move around in various ways.
Add the following lines to your .fvwm2rc file to set up key combinations to scroll one page in any direction on the desktop using Ctrl plus an arrow key. The view scrolls in the direction of the arrow.
Each definition uses the Key variable followed by:
The name of the key
The context (location) in which it must be typed
Any modifying keys (that must also be held down)
The action initiated by the key or key combination
Thus, in the following example, the first definition line says that pressing the left arrow key in any “A” context, while also holding down the Ctrl “C” key will scroll the screen one page to the left on the current desktop:
# Press arrow + Control in any context # to scroll by one page in the direction of the arrow Key Left A C Scroll -100 0 Key Right A C Scroll +100 +0 Key Up A C Scroll +0 -100 Key Down A C Scroll +0 +100
Table 17-1 summarizes the functionality.
Table 17-1. Key ...
Get Linux in a Nutshell, Third Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.