Here are some reasons why a user might want to do this:
5.2 Running Empress 4GL under xterm
The xterm program is a terminal emulator for the X Window System.
It provides DEC VT102 compatible terminals for programs that can't use
the window system directly, for Empress 4GL running in tty
mode. In general, a good xterm program should behave like a VT102.
The exception is the key mapping since most X terminal keyboards are different
from VT102s.
In order to run Empress 4GL under xterm, there are some things to be considered:
| VT100 Key Sequences | |||
| Key Name | Key Sequence | Key Name | Key Sequence |
| KP , | esc Ol | KP 7 | esc Ow |
| KP - | esc Om | KP 8 | esc Ox |
| KP . | esc On | KP 9 | esc Oy |
| KP ENTER | esc OM | PF1 | esc OP |
| KP 0 | esc Op | PF2 | esc OQ |
| KP 1 | esc Oq | PF3 | esc OR |
| KP 2 | esc Or | PF4 | esc OS |
| KP 3 | esc Os | U-Arrow | esc OA |
| KP 4 | esc Ot | D-Arrow | esc OB |
| KP 5 | esc Ou | R-Arrow | esc OC |
| KP 6 | esc Ov | L-Arrow | esc OD |
5.2.1 Create an X resource file for VT100 key emulation
Examples
X Terminal with 101 Keyboard
If your X Terminal has a 101 Keyboard, the keys, which the VT100 terminal has and your X terminal does not, are KP_comma, PF1, PF2, PF3, PF4. (assuming the other keypad keys have been mapped correctly by your X Server).
You can map:
Table 5-2
| X Terminal key | VT100 key |
| F1 | PF1 |
| F2 | PF2 |
| F3 | PF3 |
| F4 | PF4 |
| KP_Add | KP_comma |
101kb*VT100*translations: #override\
<Key>F1: string(0x1b) string("OP") \n\
<Key>F2: string(0x1b) string("OQ") \n\
<Key>F3: string(0x1b) string("OR") \n\
<Key>F4: string(0x1b) string("OS") \n\
<Key>KP_Add: string(0x1b) string("Ol")
where 101kb is the client name, 0x1b is escape key.
You can create an X resource file and run xrdb -merge <file> or add these lines to a primary resource file (often called .Xdefaults or .Xresources) in your home directory. You can bring up an xterm program by running xterm -name 101kb &.
xterm(1), shelltool(1) (X version), xrdb(1), X Window System User's Guide, /usr/include/X11/keysymdef.h
5.4.1 Text Cursor
The text cursor is displayed as a box and is a combination of a foreground
(character) color and background (space) color. By default, these colors
are the inverse of the colors of the character position on top of which
the cursor is displayed. The colors of the text cursor can be modified
by setting the variable MS4GLXCURSORCOLOR to a four-digit number. The first
two digits identify a color in the 4GL colormap to be taken as the foreground
color and the last two digits as the background color. For example, using
the 4GL default colormap, a white cursor with red characters would be defined
by the number 0100.
5.4.2 Pointer Cursor
The pointer cursor is displayed as a cross hair. By default, the foreground
color is black and the background color is white. Also, most of the background
has been eliminated by masking it out. The colors of the pointer cursor
can be modified by setting the variable MS4GLXPOINTERCOLOR to a four-digit
number similar to the way the text cursor is defined above.
The shaped of the pointer cursor can be modified by editing the files pointer.ci and mask.ci in the custom directory and executing mkbins followed by mkexec on the executables emp4fulg and emp4rtg. The pointer.ci file contains a bitmap defining the foreground and background pixels of a box shaped area that is the pointer cursor. The mask.ci file contains a bitmap indicating which pixels of the box shaped area are to be displayed. The mask.ci file is used to shape the pointer cursor by eliminating unwanted areas of the box. Both files should be edited using the X Windows command bitmap.