Editing layout’s modifiers table is another major function of the Low level editor. The entire lower half of the Low level window is dedicated to this task.
Modifier keys do not produce any characters themselves, but their combined state (on/off) defines which (if any) characters are generated by character-producing keys. KbdEdit supports four standard modifiers: SHIFT, CTRL, ALT and the less known KANA modifier.
Active vs. Unused modifier combinations
Combined state of all modifier keys defines a modifier combination. As each modifier can have two states (on/off), the total number of all possible combinations is 2 ^ <number of modifiers>. For the most common case of 3 enabled modifiers (SHIFT, CTRL, ALT), there are 8 theoretically possible combinations.
Depending on a particular layout, not all possible combinations are actually needed. For instance, standard US English keyboard uses only 4 combinations (BASE, SHIFT, CTRL and SHIFT+CTRL). ALT combinations are not used at all, and most keys do not even have a CTRL or CTRL+SHIFT mapping. The layouts that do use ALT do so only for a limited number of ALT combinations, typically only ALT+CTRL and sometimes SHIFT+ALT+CTRL.
To avoid redundant empty high-level mappings for unneeded combinations, a list of used combinations can be defined, separating them from the unused ones.
Modifier combinations that are valid for a given layout are displayed in the Active modifier combinations list. The combinations shown here are available for mapping in the High level editor. Remaining combinations are listed in the Unused modifier combinations.
Combinations can be moved from one list to the other using the buttons ‘←’ (left arrow) and ‘→’ (right arrow). The number of active combinations is limited to 10 for practical reasons.
When a combination is removed from the “active” list, all of its “high-level” mappings are lost too. In this case KbdEdit will prompt you to confirm this potentially destructive operation.
Modifier combinations appear in the High level view in the same order as in the “Active modifier combinations” list. This order too can be changed: the buttons ‘↑’ (up arrow) and ‘↓’ (down arrow) move the current combination up and down.
BASE combination (no modifier pressed) is somewhat special: it is always active, and must be the first element in the list of active combinations.
Modifier virtual codes
For standard SHIFT, CTRL and ALT modifiers separate virtual codes exist for “left” and “right” versions: left SHIFT is represented by VK_LSHIFT, right SHIFT by VK_RSHIFT, and the same goes for VK_LCTRL/VK_RCTRL and VK_LMENU/VK_RMENU. The distinction between “left” and “right” variants is immaterial to the end user; it exists only to make it easier for Windows to handle keyboard input.
ALT modifier’s virtual code is named VK_xMENU instead of something like VK_ALT. The reason is historical: initially, the primary function of the ALT key was keyboard navigation through Windows menus.
KbdEdit allows KANA virtual code to be set to either VK_KANA or VK_OEM_8. This is done through the KANA mapped to combo box, which is enabled if KANA is enabled. KANA modifier is special in that it behaves differently depending on which virtual key it is mapped to:
KbdEdit does not check if the necessary modifier virtual codes are actually mapped to physical keys – it is up to the user to verify that the low-level mappings are correct. If CTRL is enabled, but no physical keys are mapped to VK_xCTRL, this modifier will effectively be turned off, which might or might not be the intent.
Each modifier can be turned on/off using a checkbox placed next to its name. If a modifier is turned off, all combinations it is part of are removed from "Active" and "Unused" lists. All "high-level" mappings for the removed "Active" combinations are also deleted.
You should keep in mind that even if you deactivate the “modifier” function of a modifier key (by turning its check box off), the modifier key’s virtual code will still keep its non-modifier functions. For instance, if you deactivate ALT modifier, Windows system shortcuts involving the Alt key will still be accessible (task switching using Alt+Tab, application menu access through Alt+<letter> etc).
To completely disable a modifier key, including all keyboard shortcuts it is part of, it is necessary to remove the modifier virtual code from the underlying physical key(s). This is done either by assigning an “empty” code to the physical key (as described in Editing virtual key mappings), or by assigning it a different virtual code which effectively changes the key’s function.
Using the same example, ALT key is completely disabled by removing the underlying virtual keys VK_LMENU and VK_RMENU from the layout. The physical keys can be either disabled (assigning VK__none_), or their function can be changed by assigning a virtual code other than VK_LMENU / VK_RMENU / VK__none_.
Three special flags enable additional modifier-related fine tuning: "Uses AltGR", "SHIFTLOCK" and "LRM RLM".
As stated above, ALT modifier is rarely used alone. It is almost always used in conjunction with CTRL, treating the combination CTRL+ALT as a "virtual" modifier key called ALTGR.
If Uses AltGr is checked, "ALTGR" is shown instead of “CTRL+ALT” throughout the KbdEdit GUI. This is not a mere cosmetic change: in "Uses AltGr" layouts, right ALT is also treated differently by Windows: pressing it has exactly the same effect as pressing CTRL and (left) ALT together.
A less known special flag SHIFTLOCK can be used to change the interplay of SHIFT and Caps Lock: if SHIFTLOCK is checked, Caps Lock is turned off by pressing SHIFT (normally, Caps Lock is turned off by pressing the Caps Lock key again).
The default effect of Caps Lock on SHIFT is somewhat counter-intuitive: the SHIFT state is effectively inverted while Caps Lock is On (see Caps Lock-related special settings). SHIFTLOCK can be used to correct this problem: it makes SHIFT behave in a predictable fashion independently of Caps Lock state.
LRM-RLM flag is useful for languages like Arab or Hebrew which are written from right to left. If LRM-RLM is checked, two special shortcuts are activated which enable the keyboard to be used in bidirectional mode:
Back to Low-level editor
Copyright © KbdSoft 2007-2013