
How to detect Caps Lock/Scroll Lock/Num Lock state?
Is there a way to detect whether the lock functions are currently enabled or not? Based on this issue it seemed like the intention was for the key to be considered down while the lock was enabled and up while it's not, but it doesn't seem to function that way anymore. Checking the state of any of the lock keys just reflects the physical state of the key itself.
ChatGPT suggests the only solution is to write platform-specific implementations that use native APIs to check this. I can do that if I need to, but was surprised there wasn't something built in so wanted to check before I add that kind of complexity to my codebase.