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

Arabic native-to-Swing cut & paste is broken.

    • sparc
    • solaris_8


      Run the attached program. Click on the JTabbedPane tabs until all the panes are
      visible. Finish preparation by clicking on the tab "Swing JTextFields".
      Twenty different JTextFields are in this pane. They are arranged in 4 columns
      and 5 rows.

      Copy the language String from the command line (or any other Arabic from
      an X-terminal). Paste it into one of the JTextFields. Nothing happens.
      Copy and paste English text and all is well.

      algol% uname -a
      SunOS algol 5.8 Generic_108528-06 sun4u sparc SUNW,Ultra-2
      algol% echo $LANG
      ar
      algol% java -version
      java version "1.4.0-beta_refresh"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta_refresh-b71)
      Java HotSpot(TM) Client VM (build 1.4.0-beta_refresh-b71, mixed mode)

      allan.jacobs@Eng 2001-07-16

      Attached a (pretty stupid and simple) code JT.java. It's much smaller than
      FontTest.java.
      (1) Give JT's JFrame focus. Type Ctrl-Space so that the Arabic input method
          is activated.
      (2) Type Arabic into JT's JTextField.
      (3) Select the new Arabic text. Hit the sparc "Copy" button.
      (4) Go to a native X-window, give it focus. Type Ctrl-Space so that the Arabic
          input method is activated. Hit the sparc "Paste" button.
          The Arabic will be copied. But there will be a Latin character at the
          end of the paste.
      (5) Return to the JTextField. Select and delete the Arabic. Type some
          new Arabic in. Select the new Arabic using the left mouse button.
      (6) Go to the native X-window, give it focus, and paste the Arabic using
          the middle mouse button. The Arabic will be copied. But there will be
          a Latin character at the end of the paste.
      (7) Return to JT. Delete the text there.
      (8) Go to the native X-window, give it focus, and enter some Arabic text.
          Use the left mouse button to select. Hit the sparc "Copy" button.
      (9) Return to JT. Hit the sparc "Paste" button. Nothing will happen.
      (10) Delete the text in JT.
      (11) Return to the X-window. Enter some Arabic text. Use the left mouse
          button to select.
      (12) Return to JT. Hit the middle mouse button. Nothing happens.

      ###@###.### 2001-09-18

      Danila Sinopalnikov (###@###.###) sent a utility dumpsel.c that dumps
      the contents of the clipboard on demand. It has been attached. The results
      are attached to this bug report, too -- in the file arabic_8.sel.

      java version "1.4.0-beta3"
      Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0-beta3-b80)
      Java HotSpot(TM) Client VM (build 1.4.0-beta3-b80, mixed mode)

      ###@###.### 2001-09-24

            dassunw Das Das (Inactive)
            ajacobssunw Allan Jacobs (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: