Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-5026508

Demo CodePointIM: should use KEY_TYPED event instead KEY_PRESSED

XMLWordPrintable

    • b49
    • generic
    • generic

      -----------------------------------------------------------------------------
      The input method engine SPI tutorial says: "Note: For key events, input
      methods should use only KEY_TYPED events to obtain information about
      characters being entered, and use KEY_PRESSED or KEY_RELEASED events only
      to obtain information about function keys that don't result in KEY_TYPED
      events. The mapping from key-presses to characters depends on platforms,
      hardware, locales, and possibly other factors, and is best left to the
      underlying operating system."

      Similarly, the KeyEvent class description says: "Key typed events are
      higher-level and generally do not depend on the platform or keyboard
      layout. They are generated when a Unicode character is entered, and are
      the preferred way to find out about character input." -----------------------------------------------------------------------------

      CodePointInputMethod uses KEY_PRESSED event for handling Delete, BackSpace,
      Escape, Enter and Tab. KEY_TYPED should be used for handling them instead.

            peytoia Yuka Kamiya (Inactive)
            peytoia Yuka Kamiya (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: