Is there any way to get the keycode of a char? For example
getKeycode(\'C\');
Is there anything like that?
Thanks
public static int KeyEvent.getExtendedKeyCodeForChar( int key );
This will return an extended key code for the unicode character key.
As stated at here:
Returns: for a unicode character with a corresponding VK_ constant -- this VK_ constant; for a character appearing on the primary level of a known keyboard layout -- a unique integer. If a character does not appear on the primary level of a known keyboard, VK_UNDEFINED is returned.