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

TextBox getText() returns nothing when called from an onKeyXX event

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: fx2.0
    • Fix Version/s: fx2.0
    • Component/s: javafx
    • Labels:
    • Environment:

      Windows 7, Java 1.6.

      Description

      Calling getText() returns nothing when called from an onKeyXX event.

      You have to call getRawText() to get the current text contents.

      This is, in my opinion, nuts and utterly confusing.

      If you want to differentiate between committed/uncommitted text, how about removing getText() and getRawText() and going with getUncommittedText() and getCommittedText().

      Or have getText() return the current contents, and introduce getCommittedText();

        Attachments

          Activity

            People

            • Assignee:
              gkbrown Greg Brown (Inactive)
              Reporter:
              sherodjfx Steven Herod (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported: