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

JFormattedTextField with url format shows / in front of the url

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: P4
    • Resolution: Unresolved
    • Affects Version/s: 17
    • Fix Version/s: 18
    • Component/s: client-libs
    • Labels:
      None
    • Subcomponent:
    • Introduced In Build:
      b12
    • Introduced In Version:
      17
    • CPU:
      x86_64
    • OS:
      generic

      Description

      I have a frame with different type of JFormattedTextField. All the JFormattedTextField are set to Right to Left orientation & do see the JFormattedTextField and its content are set correctly expect URL format.
      The url is very simple http://www.oracle.com/ . The character / is seen before the the url in case of Right to left.

      Attached two test cases
      1) Testcase JFormattedTextFieldRTLTest.java shows different JFormattedTextField with Right to left orientation
      2) Testcase JFormattedTextFieldWithURLFormatBug.java shows only JFormattedTextField one with Left to right and another with right to left which is a simplified version of the first case.

      Step to reproduce
      1) Run both the test cases and observe that Right to left orientation url formatted JFormattedTextField value where character / is seen before http. If you see the same then the bug is reproduced.

      This is introduced in JDK 17 b12 onwards. This works fine in older JDK tested from JDK 8 onwards till JDK 17 b11.
      Reproduced on Ubuntu and Mac 10.15.7 macOS Catalina.

        Attachments

          Activity

            People

            Assignee:
            psadhukhan Prasanta Sadhukhan
            Reporter:
            landrews Lawrence Andrews
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated: