The print screen key does not trigger the event
The print screen key does not generate a WM_KEYDOWN event, only a WM_KEYUP event.
It is clear to me that mIRC waits for WM_CHAR and WM_DEADCHAR in both control + a and the '^' situation to set $keychar
mIRC does not wait for WM_CHAR or WM_DEARCHAR. The on KEYUP/DOWN events are triggered by WM_KEYUP/WM_KEYDOWN. These use the ToUnicode() API, which performs a conversion to set $keychar and, due to how ToUnicode() works, affects subsequent keyboard messages.
Thanks for your comments.