Monday 28 November 2011

What is a dead key? in C programming

What is a dead key?

A dead key is a keystroke that is not recognizable by Windows. On some international keyboards, it is impossible to translate certain characters into keystrokes. In this case, Windows sends either a WM_DEADCHAR or a WM_SYSDEADCHAR message to your program, indicating that Windows cannot interpret the character code of the incoming keystroke

You can, however, manually reference the actual ASCII character code of the incoming character. When your program receives one of these two messages, you can inspect the value of the wParam parameter and determine which key was pressed. You therefore can manually customize your programs for internationalization by determining ahead of time which foreign characters your program needs to handle.

Cross Reference:

XXI.15: What are OEM key codes?
XXI.16: Should a Windows program care about the OEM key codes?
XXI.17: What are virtual key codes?

No comments:

Post a Comment