JDK-8120052 : TextArea/TextField, caret issue for Thai characters.
  • Type: Bug
  • Component: javafx
  • Sub-Component: controls
  • Affected Version: 8
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2012-11-14
  • Updated: 2015-06-17
  • Resolved: 2013-08-22
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 8
8Fixed
Related Reports
Blocks :  
Description
8.0 b64. Copy some Thai characters to TextArea/TextFiled, check caret movement when pressing LEFT and RIGHT keys.
The is an issue that the caret stop for a while at the complex characters. For example,  "���������" is a complex character, it includes 3 separate characters, then it needs to press arrow key 3 time to move to next character. But for JDK or native apps, it only need to press arrow key once.

Deleting(by DELETE key, deletes characters after caret) characters also behaves different from JDK and native apps. for "���������", native apps delete it by pressing DELETE once, JDK deletes it by pressing DELETE 3 times, but during deletion, the remain characters will be expanded to separate characters. JavaFX deletes each part on the spot, also needs 3 times.
Comments
The original issue is verified fix with b105. A new issue is filed as RT-32717.
05-09-2013

The fix was to use BreakIterator.getCharacterInstance() for all character navigation actions, such as forward, backward, and delete. The only deliberate exception is delete backwards (backspace), where complex character clusters such as the Thai character mentioned in the description should be broken up step by step (three steps in this case). A utility method getHitInsertionIndex() was also added as a workaround for RT-26961, so that the entire complex character is skipped when HitInfo.isLeading() is false. Changeset: http://hg.openjdk.java.net/openjfx/8/controls/rt/rev/9659769d6d54
22-08-2013

added screen shots for Swing JTextArea and gedit sample for deleting Thai.
14-11-2012