What Do I Do If Characters Cannot Be Entered or Deleted in the Text Box, and the Background Reports the "java.lang.RuntimeException: java.awt.event.KeyEvent" Error?

Symptom

When a user uses a Windows device to remotely connect to MindStudio on a Linux device through another Windows device, characters cannot be entered or deleted in the text box, and the background reports the "java.lang.RuntimeException: java.awt.event.KeyEvent" error.

Figure 1 Error example

Fault Analysis

Keyboard mapping exists between Windows remote connection and X11 forwarding. If the mapping is incorrect, keyboard inputs cannot be correctly identified.

Solution

  1. Run the localectl command in Linux to view the keyboard configuration of the device. Information similar to the following is displayed:
    System Locale: LANG=en_US.UTF-8
    LANGUAGE=en_US:en
    VC Keymap: n/a
    X11 Layout: cn
    X11 Model: pc105
  2. Configure the X11 options on MobaXterm.

    Choose Settings > Configuration on the menu bar. In the MobaXTerm configuration window that is displayed, click the X11 tab, deselect Unix-compatible Keyboard, and set KeyBoard to the X11 Layout value obtained in 1. See Figure 2.

    Figure 2 X11 configuration window
  3. If the error persists, restart MindStudio.