0
$\begingroup$

I have bought a laptop that was German (I’m not, I use an English keyboard), and I have a clean installation in English as Win 10 OS language and Greek loaded as an additional language pack. Both use a QWERTY layout, whereas German uses QWERTZ. To maintain my keyboard habits I physically flipped the Z/Y keys to have the alphabet keys in place (and re-tagged the 4 keys with the basic punctuation marks in the familiar QWERTY positions - I am putting this in parentheses because if I solve the first issue, read more, this will follow). Apart from the alphabet keys there are more than a dozen keys that differ (such as the shift numbers and others at the keyboard extremities). Those I don’t normally type “blind”, I look for them and press the key, as tagged. In order not to re-tag physically all the keys and make a mess of my laptop, I used Microsoft’s Keyboard Layout Creator to match the key codes with the key tags. To save myself retyping all the keyboard codes in basic, shift and AltGr shift combinations, I originated my custom keyboard with the German layout and changed only a couple of keys that I physically replaced, the Z/Y and the punctuation marks above. I saved the layout as English Language Layout and everything has been working fine: it is available as an English language alternative keyboard, I type what I see on the keys (wysiwyg) and spellchecks properly identify the language.

Not in Blender, not in parts of Blender anyway: In the viewport pressing Z which normally restrains along the Z-axis, restrains the Y and vice versa. But when I type text in a text file in blender Z is again Z… Somehow on occasions gets the blender key input at a lower level than the keysetup from Layout Creator, ignoring the setting that this keyboard is an English variant.

Any ideas?

$\endgroup$

1 Answer 1

0
$\begingroup$

Solved, I needed to remap the virtual keys, to the proper scancode. Did that manually editing the .klc file, because I found no way to do it in MS Layout Creator. Then I just used the Creator to generate the setup files, from the edited .klc .

Detail by example:

  1. I have physically switched the z/y keys on the keyboard
  2. I have used MS Keyboard Layout Creator to alter the German keyboard so as to type "z" in scancode location 2C (View this webpage for scancode / virtual key settings by locale)
  3. I have named the custom keyboard that matches my physical layout "Deunglish" However because Deunglish started of as a German keyboard the Virtual Key VK_Y is still mapped to scancode location 2C, despite setting this as an English keyboard with Creator.
  4. Open the Deunglish.klc file with Notepad++ (or other editor) and replace "y" (virtual key name) with "z" for scancode 2C.
  5. Now you will have two definitions for VK z, assigned to two different scan codes, in this case scancode 15. Change that to y as you did for z.
  6. Load the klc file in the MS, verify and Build DLL and setup (If you had been using the keyboard you have just edited, you need to unload and uninstall the previous version first. You will likely need to restart)

You have successfully swapped virtual keys and assigned them to positions on the keyboard! Do this for all keys that may need proper virtual key name to actual output matching, and/or to set to virtual keys to new scan codes.

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .