-
Notifications
You must be signed in to change notification settings - Fork 123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Only some keys sent to keyboard handler on Windows #59
Comments
Hi, |
Thanks for reply. I noted that at least the JUCE host sends WM_CHAR to the plugin, so I could hack win32frame.cpp copying code from WM_KEYDOWN to WM_CHAR:
Not sure if that's the correct way to do it, one needs to use utf8 codecvt facet to create VSTGUI strings. Just using a copy of the code, but I can look at pull requesting. |
The wide string to utf8 string conversion can be done via the UTF8StringHelper class from winsupport.h |
CFrame onKeyDown/Up etc only get a small subset of keys, ie the ones listed in vstkeycode.h struct VstVirtualKey, ie shift, ctrl, space, F1-F12, arrows etc.
But no letters or digits.
In fact it looks like the VstKeyCode .character member is always 0 on windows.
If I read Mac code in /platform/mac/ cocoahelpers.mm right, this is not the case on Mac;
there the .character member is populated with ASCII value.
I can ofc hack the win32frame.cpp translateWinVirtualKey function, or use KeyboardHook,
but just wanted to note this seems an omission.
Or is there some logic to this behaviour?
Thanks,
/re
The text was updated successfully, but these errors were encountered: