Investigating a Num Lock Issue


I installed Keyman 10 for a friend today on a Windows 10 laptop and observed that numbers from the top row were not treated the say as from the number pad with Num Lock active. The first would be interpreted by Keyman and the later not.

I have had no problems with Windows 10 and Num Lock; the numbers get handled as expected in the top row numbers. How could I go about investigating what the issue is?

Yes, number pad is treated completely separately to the standard numeric keys. They have separate virtual key codes. Normally, we don’t advise remapping the number pad.

You can do so with the virtual keys K_NP0 … K_NP9 and so on; you can also use the NUMLOCK shift flag on Windows at least to test for the state of num lock (because you don’t want to modify when num lock isn’t on).

Thanks again @Marc. In the Virtual Keys documentation link, under the “Reference” section there is a table after the leading sentence “The possible shift codes are:” and the NUMLOCK shift flag is not listed. Is the documentation out of date?

Okay, sorry, it’s undocumented (and hence I should be hesitant to suggest it I guess). Note that NUMLOCK is not very cross-platform-safe!