ukhd.gif - 11Kb



For some time now, TW/EW Pro have provided the capability for users to add to, or modify ‘keyboard shortcuts’ for menu actions. This is very useful for those of us who find typing quicker than searching for menu items, or clicking the icon bar buttons, with the mouse. With Pro+ this flexible use of the keyboard has been extended.

This extension is based on the ‘UniversalKeys’ module which was produced by David Pilling, who kindly gave his permission for its use and distribution with Pro+.

If you are using Pro+ version 6.03 or higher and haven’t discovered the new features yet, try pressing the ‘/’ key on the numerical keypad to the right of the main keyboard. You should find it produces a ‘÷’ divide symbol instead of a slash. Now try the ‘*’ and ‘.’ keypad keys. These should produce a ‘×’ multiply symbol and ‘·’ decimal (mid-dot). These are examples of how the new system allows the user to reconfigure the keyboard.

To avoid duplication I won’t give a full description here of how the system works. I’ll just concentrate on the new features. If you have not tried altering the menu or keyboard behaviour of TW/EW Pro before. it might be worth you while at this point going and reading the page linked to this sentence before reading on...

Ok, you now know that this process is basically controlled by the information held in the ‘MenuData’ file inside the Pro+ application. To understand the newer features, look at the first few lines of the MenuData file that comes with Pro+.

keyx.gif - 5Kb
The first ‘real’ menu is the main one headed ‘TechWriter’ (or ‘EasiWriter’ if you have EW Pro+). This starts on the eighth line and is menu number ‘1’ in the applications internal numbering system. The lines above this refer to a mythical ‘Root’ menu, number ‘0’. This does not produce an actual menu, it is a dummy, put in so you have somewhere to add key controlling codes that aren’t linked to visible menu items.

The first item in this dummy menu is the line which has a syntax similar to that used for general menu and key control. The ‘183’ means this will enter character 183 - i.e. · (decimal point or mid-dot). The ‘0’ means this is ‘command number’ zero, so isn’t linked to a real piece of Pro+ command code. Hence there is no menu action, or way to link to the button bar. The final item uses the special code to indicate that what follows is a function key or special key definition. This is followed by ‘N-.’ where the ‘N-’ means a numeric keypad key, and the ‘.’ means the full-stop key. So this line means that when we press the ‘.’ key on the keypad it is translated into a ‘·’.

The following pair of lines link the ‘*’ and ‘/’ keys on the keypad in a similar way, so they produce multiply (character number 215) and divide (character number 247) symbols when pressed. Once you understand this syntax you can add new key actions or alter/delete the existing ones, to suit your preferences. By using ‘CN-’, ‘SN-’, or ‘CSN-’ you can specify what happens if you hold down the <ctrl>, <shift>, or both of these modifer keys when pressing the keypad key.

It is now possible to modify the action of almost every key on the keyboard if you wish. Although the usual warning, “Keep a backup copy of the MenuData file!” certainly holds. Otherwise you risk making the menu system and keyboard unusable! The extended syntax is summarised below, with details taken from the ‘V6+doco’ document that comes with Pro+. (Thanks to Icon Tech for permission to include the following.)




New Menu Keys



Many new menu key shortcuts are added. The shortcut names needed to identify these in MenuData are:

Qualifier Tab Insert End
(none) - Insert -
shift - S-Insert S-End
Ctrl C-Tab C-Insert C-End
shift-ctrl SC-Tab SC-Insert SC-End


Note: SC and CS are interchangeable; Shift-Tab is now recognised, but is reserved for use in tables to indicate a <tab> inserted within a cell.

For convenience keys are split into keypad (NumLock on and off) and non-keypad groups, although it should be noted that the application is not told the state of the lock key when the key is sent, it is just sent different key codes by the keyboard driver.

NumLock Off
Qualifier 0 .. 9 . / * - + Enter
(none) N-0 .. N-9 N-. N-/ N-* N– N-+ -
shift SN-0 .. SN-9 SN-. SN-/ SN-* SN– SN-+ SN-Enter
Ctrl CN-0 .. CN-9 CN-. CN-/ CN-* CN– CN-+ CN-Enter
shift-ctrl SCN-0 .. SCN-9 SCN-. SCN-/ SCN-* SCN– SCN-+ SCN-Enter


Enter (unqualified) is reserved to mean the same as Shift-Return (i.e. current line break)

NumLock On
Qualifier Ins End Dn PgUp Left Right Up
(none) N-Insert N-End N-Down - N-Left N-Right N-Up
shift SN-Insert SN-End SN-Down SN-PageUp SN-Left SN-Right SN-Up
Ctrl CN-Insert CN-End CN-Down CN-PageUp CN-Left CN-Right CN-Up
shift-ctrl SCN-Insert SCN-End SCN-Down SCN-PageUp SCN-Left SCN-Right SCN-Up


Plus those from the last 5 columns of the NumLock Off table.

Other keys
Qualifier Return Delete Home Page Up Page Down <— (Backspace)
(none) - - - - - -
shift - S-Delete S-Home S-PageUp S-PageDown S-Backspace
Ctrl C-M C-Delete S-Home C-PageUp C-PageDown C-Backspace
shift-ctrl SC-M SC-Delete SC-Home SC-PageUp SC-PageDown SC-Backspace




Back to the main Pro Plus page...
ppbk.gif - 2614 bytes


Pages written using TechWriter and HTMLEdit
Content and pages maintained by: Jim Lesurf (jcgl@st-and.demon.co.uk)