Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
假设我在英文键盘上按了“=”。如果我将键盘语言切换为土耳其语,按相同的键会给我一个“-”。所以我很容易说我的操作系统解释了按键。
我的问题是,是否有可能获得 a 键的实际值,以便无论使用哪种语言,我都可以知道按下了哪个键?稍后,我需要将此值与 RegisterHotKey 一起使用。
您使用虚拟键码,而不是依赖于语言的键盘扫描码。
您没有指定编程语言,但这些应该独立于语言和操作系统。虚拟键代码链接