When I’m talking regarding keyboard shortcuts to things like Ctrl-S or maybe one key shortcuts like ‘A’ (used to Archive an email on Gmail). On the opposite aspect the method, called hotkeys or the underlined letters in menus or different GUI controls are clearly one thing that ought to be localized and that I not going to argue regarding this.
I have did some analysis to check however, some different firms are handling the shortcuts once people are using different languages and different keyboard layouts. Here are a brief list of my results:
- If doable, the shortcut isn’t modified
- If a key not available on a particular layout we must always attempt to use constant physical position
- There needs to be no link between practical application language and keyboard patterns. It’s a mistake to consider that application language might match the keyboard format. I’ll reveal just a good example: in Romania over 95% of the computer systems are using US keyboard layout and the other 5% are using among the 4-5 various Romanian keyboard layouts.
- Some individuals are using several keyboard layouts – generally, they are in fact power users and we can’t ignore them
- Keyboard patterns can be converted anytime
- Characters are secure to be used only when they are Latin
Physical position rules
I think that the actual physical position of the key is a lot more important than the letter written on it. Below are my arguments:
- Human brain is understanding the shortcuts by hand movements (notice Pavlov’s dog experiment)
- It is appropriate for the usage of multiple keyboard models
However, it’s not always so easy: we can’t assume that the French users would switch the usage of Ctrl-Q with Ctrl-A (Quit vs Select All) simply because they are using different layouts. Therefore, a fundamental rule would be to stick with the format for letters and numbers. However, attempt to use the actual physical position for other keys.
Anyways high, likely those individuals using multiple layouts would select alike layouts (derived from the similar root).
One-to-one key matching
Since the number of keys is similar we need to find a way of remapping the keys so that all shortcuts working on US to be workable on different layouts. When I’m talking about keys, I’m referring to the hardware keys.
Question: How do I create OS X tell me that the key pressed by the user was ‘q’ while current format is Arabic?
- We are not allowed to consider it’s a ‘q’ because the key code is similar, probably it’s a Arabic DVORAK keyboard!
- The shortcuts should not be hardcoded (user can edit them)
On Windows it does work 98% using virtual key codes and you can use them to obtain this info, but on OS X the key codes (actually Apple call them sometimes virtual key codes) they are some kind of scan codes. For the rest of 2% you need to do some small hacks with the OEMs.