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

Double clicking a word in TextArea selects wrong word

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: P3
    • Resolution: Unresolved
    • Affects Version/s: 8, openjfx11, openjfx15, openjfx16, openjfx17
    • Fix Version/s: tbd
    • Component/s: javafx
    • Subcomponent:
    • CPU:
      x86_64
    • OS:
      windows_10

      Description

      ADDITIONAL SYSTEM INFORMATION :
      Microsoft Windows 10.
      Java 11 (Code seems to be buggy until now)

      A DESCRIPTION OF THE PROBLEM :
      Double clicking on a word in a TextArea should select the word. If you have a Word like "AAA.3X3" and you double click on the "X", "AAA" is selected.

      From the code this is OS dependant (using Mircrosoft). The code is still wrong in the current version.

      The bug is the mismatch of word recognition in TextInputControl.previousWord(boolean) which checks only for !Character.isLetterOrDigit and TextInputControl.nextWord(boolean) which checks only for ' ' and '\t'.


      STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
      * Insert "AAA.3X3" into a TextArea
      * Double click on the "X" between the 3s



      EXPECTED VERSUS ACTUAL BEHAVIOR :
      EXPECTED -
      "3X3" or "AAA.3X3" should be selected
      ACTUAL -
      "AAA" is selected

      CUSTOMER SUBMITTED WORKAROUND :
      You can select with Shift/Ctrl and arrow keys or dragging pressed mouse.

        Attachments

          Activity

            People

            Assignee:
            aghaisas Ajit Ghaisas
            Reporter:
            webbuggrp Webbug Group
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated: