User Keyboard Maps
The FacetWin DT terminal emulator has the capability for the user to map
selected keys to output up to 100 characters when the selected key is pressed. The
keyboard mappings are defined in a user keyboard mapping file which has the
extension ".fwk" (for FacetWin DT Key file). These keyboard mapping files must be
in a sub-directory called "UserKey" under the FacetWin installation directory
on the Windows PC. For example, if FacetWin DT was installed in:
C:\Program Files\FacetCorp\FacetWin
then the FacetWin DT keyboard mapping files must be located in:
C:\Program Files\FacetCorp\FacetWin\UserKey
A keyboard mapping file can be selected for each FacetWin DT Terminal
configuration. The keyboard mapping is selected on the Property sheet Emulation Tab. The pull-down list box titled "User Keyboard Mapping" will contain a list
of all keyboard mapping files found in the UserKey directory.
A keyboard mapping file consists of one or more lines (one line per key to
map) with the syntax:
[ CTRL/ ][ ALT/ ][ SHIFT/ ]keyname SEQ=sequence_to_send
For example:
CTRL/SHIFT/F4 SEQ=hello\r
means that when the Ctrl and Shift keys are depressed, the F4 key will send
the string “hello” with a carriage return afterwards.
Each line of a keyboard mapping file has the following characteristics:
- Each line is limited to 256 characters. Note that some UNIX systems may lose
part of the sequence if a very long sequence is sent.
- Blank lines and lines that begin with "#" are comments.
- White space consists of multiple space and/or tab characters.
- White space at the beginning of the line is optional.
- There can be no white space between the "CTRL/", "ALT/", and "SHIFT/"
modifiers and the keyname.
- There must be white space between keyname and "SEQ=".
- Any white space after "SEQ=" is part of the seqence_to_send.
- There is no line continuation character.
When the emulator reads in a keyboard mapping file to use, any errors in the
keyboard mapping specifications will be recorded in the error file if that error
handling option is enabled. Also, if the “beep” error handling option is enabled, keyboard mapping errors will cause the
emulator to beep. These error handling options are on the Options Tab of the Property sheet.
keyname is one of the following:
For the standard typewriter keys, use the printable character that the key
would normally send. For example, ‘A’, or ‘a’ both refer to the “A” key, and you could specify a sequence to be sent when Alt-a is pressed with
either:
ALT/a SEQ=xxx
or
ALT/A SEQ=xxx
Special keys are denoted by the following identifiers:
ESC is Escape key
TAB is Tab key
BACKSPACE is Backspace key
ENTER is Enter key (not on keypad)
SPACE is Space bar
F1, F2, ... F24 are Function keys (most keyboards only have 12)
PRINTSCREEN is Print Screen key
PAUSE is Pause key
INSERT is Insert key (not on keypad)
HOME is Home key (not on keypad)
PAGEUP is Page Up key (not on keypad)
DELETE is Delete key (not on keypad)
END is End key (not on keypad)
PAGEDOWN is Page Down key (not on keypad)
UPARROW is Up arrow key (not on keypad)
LEFTARROW is Left arrow key (not on keypad)
DOWNARROW is Down arrow key (not on keypad)
RIGHTARROW is Right arrow key (not on keypad)
KP_/ is / key on keypad
KP_* is * key on keypad
KP_- is - key on keypad
KP_+ is + key on keypad
KP_ENTER is Enter key on keypad
KP_. is . on keypad with Num Lock on
KP_0, KP_1, ... KP_9 are 0 through 9 on keypad with Num Lock on
KP_HOME is Home on keypad with Num Lock off
KP_UPARROW is Up arrow on keypad with Num Lock off
KP_PAGEUP is Pg Up on keypad with Num Lock off
KP_LEFTARROW is Left arrow on keypad with Num Lock off
KP_CLEAR is 5 key on keypad with Num Lock off
KP_RIGHTARROW is Right arrow on keypad with Num Lock off
KP_END is End on keypad with Num Lock off
KP_DOWNARROW is Down arrow on keypad with Num Lock off
KP_PAGEDOWN is Pg Dn on keypad with Num Lock off
KP_INSERT is Ins on keypad with Num Lock off
KP_DELETE is Del on keypad with Num Lock off
You may also map the shift keys themselves, but this is highly discouraged
since the key will lose its shift state meaning. The following identifiers refer
to the shift keys:
CAPSLOCK is Caps Lock key
SHIFT is Either Shift key
CTRL is Left Ctrl key
RIGHT_CTRL is Right Ctrl key
ALT is Left Alt key
RIGHT_ALT is Right Alt key
Windows takes over some keys in certain shift states for its own use, such
that these cannot be mapped at all. The following keys cannot be mapped for this
reason:
ALT/TAB
ALT/ESC
CTRL/ESC
ALT/F6
SHIFT/ALT/F6
FacetWin DT also does not allow the mapping of:
Num Lock
Scroll Lock
The sequence_to_send is composed of normal printable characters, plus the following combinations
which indicate special or unprintable characters:
\\ is BACKSLASH
\b is BACKSPACE
\n is NEWLINE
\r is RETURN
\s is SPACE
\t is TAB
\e is ESCAPE
\E is ESCAPE
\x[0-9 a-f A-F] is HEX equivalent of character
\[0-7][0-7][0-7] is OCTAL equivalent of character
\OTHER is OTHER
^? is 0x7F
^@ to ^_ is 0x00 to 0x1F
^` to ^~ is 0x00 to 0x1E