Ich benutze eine Java-Bibliothek namens JNativehook, um Eingabeereignis auf Lubuntu und Windows zu erhalten, Mein Problem ist, wenn ich einen Buchstaben auf Lubuntu mit einem arabischen Tastaturlayout erhalte ich den englischen Nachbarn des Schlüssels, aber wenn ich Benutzte die Bibliothek unter Windows Ich erhielt den richtigen Schlüssel, Warum passiert das? und wie kann ich es reparieren? Hier ist mein Code:Linux Tastaturlayouts
public void nativeKeyTyped(NativeKeyEvent e)
{
System.out.println("char: " + e.getKeyChar());
}
I 2.1 von hier https://oss.sonatype.org/content/repositories/snapshots/com/1stleg/jnativehook/2.1.SNAPSHOT/ herunterladen, aber das Problem noch schlimmer, wenn ich ein arabisches Zeichen Typen I seltsame Zeichen und eine Menge von Ereignissen und diese nur einen kleinen Teil des Empfang Ausgabe
INFO: hook_event_proc [314]: Key 0 typed. (罟)
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (ý
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (罟)
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed.()
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed.()
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (ý½
Oct 19, 2016 4:43:27 PM org.jnativehook.GlobalScreen$NativeHookThread enable
INFO: hook_event_proc [314]: Key 0 typed. (罟)
Char:
Die Version, die ich verwende ist 2.3 – sam01
Sie verwenden 2.0.3, 2.1.0 wird die Fix-Version sein;) –
Aber die letzte binäre Version ist 2.0.3 https://github.com/kwhat/jnativehook/ Releases, Soll ich die Quelle kompilieren? – sam01