3

I've come to the realization that the NumLock key is useless. As far as I can tell, its sole reason for existing is to cause me several seconds of frustration whenever I accidentally turn it off.

In my crusade against this malicious key, I made it automatically enabled at startup, and used KbdEdit to remap it to the Kana modifier key, which is apparently an obscure modifier similar to Ctrl or Shift, except that it can be toggled on/off like CapsLock or NumLock. This is great and has allowed me to add some useful new functionalities to my keyboard, but now the NumLock light is perpetually lit, redundantly signifying my always-on NumLock status.

And so, as a final step in this battle for practicality, I'd like to repurpose this light to show whether or not the Kana modifier is currently active. How can I go about doing this?

In order of significance, an ideal solution:

  1. Works consistently
  2. Uses minimal external software
  3. Works on multiple versions of Windows

2 Answers2

4

Thanks to the link from the answer above and the fact that I am an AutoHotKey user. I could provide a pure AutoHotkey Script for the demanded functionality.

What the Kana key does is changing the Input from Kana to Romanji and vice-versa. I tested it and got that behavior.

Thanks to the already made LED implemantion from: https://autohotkey.com/board/topic/9587-keyboard-led-control-capslocknumlockscrolllock-lights/ it makes things pretty easy. (Thank you, Ross Presser for taking your precious time to link it) Taking that code for granted and already imported... In AutoHotKey it would be used like:

    Kana_Romanji := false
    ; Now making a hotkey for Kana Modifier Key (0x15 / VK_Kana, in AHK = vk15)
    vk15:: 
    if Kana_Romanji ;  swap the off and switch to swap the LED state for it. Currently: Romanji when it is on, Kana when it is off.
        KeyboardLED(2, "off")  
    else
        KeyboardLED(2, "switch") 
    Kana_Romanji := not Kana_Romanji
    return

A pure AutoHotKey script for the same functionality would be:

    Kana_Romanji := false
    ; Now making a hotkey for NumLock
    NumLock:: ; Change this to "VK15::" if your layout is using the key and delete the send {vk15} or comment this and uncomment the below one.
    Send {vk15} ; Actual Kana_Modifier key as given from MSDN
    sleep 10 ; Needs some delay because without delay Windows picks up the actual NumLock state and turns the light off. At least it did when I tried without it.
    if Kana_Romanji ;  swap the off and switch to swap the LED state for it. Currently: Romanji when it is on, Kana when it is off.
        KeyboardLED(2, "off")  
    else
        KeyboardLED(2, "switch") 
    Kana_Romanji := not Kana_Romanji
    return

A ready script that should work for you: https://pastebin.com/c3dcD8Gs (Read/Verify it, Save it as .ahk and open it with AutoHotKey.)

PS: I am also a NumLock key hater. Except that I always keep it off and never use it to type the numbers. It is tested in the outdated known as vanilla version of AutoHotKey (Version 1.0.48.05) but it should work on the newer ones too.

I hope it is what you need. Good luck.

1

I think you will have to rely on other software. For example, AutoHotkey can control the lights separately from the actual functions. However since the Kana modifier is little known in the AutoHotkey world, you'll have to write your own script to make the light reflect that status.

Ross Presser
  • 1,470