HDS ViewStation System Administrator's Guide

A Hypertext Document


Customizing the ViewStation's Keyboard

This page describes customizing the ViewStation's keyboard. It includes references to keyboard diagnostic tools. Changing the keyboard's mapping (with xmodmap) is discussed as well as event translation resources for application programs.

Key Handling in a Client/Server Environment
One objective of Client/Server architecture is to handle configurations such as keyboard layouts or keypress assignments separately, either on the server or on the client, so communication between the two is independent of the actual configuration of either. What this means for keyboards and keymaps is that the X terminal server handles everything about the keyboard configuration (hardware connections, keyboard layout, etc.) and produces a resulting key function called a "keysym". This keysym is a neutral function, such as "A" or "Backspace" or "F4". The client application receives this keysym and interprets it according to its own configuration (F4 may mean "Save and Exit" or "Next Page" or something else).

In this way a keysym, such as "F24", may be generated by any keyboard configuration (such as different keyboard layouts, multinational languages, use of Shift or other modifier keys, etc.) on the X terminal. This keyboard configuration is handled by a server file called xmodmap.

At the same time, the "F24" keysym may be interpreted by clients in any way they wish (such as "Home the cursor" in one application, "Insert marker text" in another, and "<string = your email address>" in another). This keysym interpretation is handled by a client resource called an event translation. This design lets any user produce an "F24" keysym, with whatever keyboard configuration, and have F24 produce the expected behavior on any application. For the user wanting to modify the keymapping, there are two avenues of approach:
1. Change xmodmap (the keyboard configuration file to produce the keysym on the X terminal), or
2. Change the event translation file (to interpret the keysym in the client application )

There are some considerations that will influence your choice.
Changing xmodmap (the Keyboard Mapping on the ViewStation) You can change the ViewStation's keymapping (both keyboard and mouse), but these changes will apply to everything you do. This may be desired in the case of switching mouse buttons for a left-handed user, or using a multinational keyboard. However, for most cases, this change is too broad and may introduce unexpected behavior and problems for your application programs.

Changing the event translation (the Keysym Interpretation on the Client) In most cases, this is the desired action since it applies to a specific application and key behavior. This change requires modifying the event translation resource for the client in your .Xdefaults file. Both of these methods are described on separate pages, with examples.

X Keymapping Tools
This section describes some X clients that are convenient tools for analyzing keymaps.

Using Xmodmap to Customize a Keyboard
This page discusses Xmodmap and redefining keyboard keys.

Using Event Translation Resources
This page describes event translation resources to change keymaps for your application programs.

HDSterm Event Translation Resources and Examples
This page describes event translation resources for the ViewStation's HDSterm client; examples are included.

Return to Section Heading Page


Return to the Home Page

If you need more information than is available here, you can reach HDS via email at info@hds.com, or call us at 1.800.HDS.1551 in the USA, or at +610.277.8300 from outside the US. For questions or problems regarding the HDS WWW page, contact webmaster@hds.com.
© 1996 by HDS Network Systems Inc.