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

[macosx] Button painting error under Java 7 on Mac

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b84
    • OS:
      os_x
    • Verification:
      Verified

      Backports

        Description

        JButtons are painted when embedded in JToolBars on Java 7 in combination with using the "segmentedTextured" client property button type seems not work well on Mac

        Check screenshots for running demo app under Java 6 and Java 7 on Mac (OS X Mountain Lion):

        Java 6:

        The rightmost buttons have been polished to look more "Macish" with the help of the following code:
        putClientProperty("JButton.buttonType", "segmentedTextured");


        Java 7:

        Executing the same code on Java 7 shows that the "segmentedTextured" client property of the buttons in the rightmost toolbar breaks the painting. At least it doesn't look good to have the buttons only painted to the left and right. When adding a 20x20 px icon to a button, it actually paints ok, so pretty certain that this is a painting bug.

        Attached an executable jar file for this demo app and the source code.

          Attachments

          1. ButtonPaintError.jar
            4 kB
          2. ButtonPaintError.java
            2 kB
          3. On Java6.png
            On Java6.png
            37 kB
          4. On Java7.png
            On Java7.png
            37 kB

            Issue Links

              Activity

                People

                Assignee:
                serb Sergey Bylokhov
                Reporter:
                tyao Ting-Yun Ingrid Yao (Inactive)
                Votes:
                0 Vote for this issue
                Watchers:
                6 Start watching this issue

                  Dates

                  Created:
                  Updated:
                  Resolved: