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

GTK LaF should use pre-multiplied alpha same as cairo

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 25
    • 21, 24, 25
    • client-libs
    • b20

      The GTK look-and-feel engine paints various UI components using gtk and cairo. The images obtained are then painted to the Swing component with drawImage().

      The pixels that cairo produces have their alpha components pre-multiplied as per the documentation:
      https://www.cairographics.org/manual/cairo-Image-Surfaces.html?spm=a2ty_o01.29997173.0.0.540ac921z2EebT#cairo-format-t

      However, the Java code that reads those pixels assumes that alpha is not pre-multiplied and therefore the resulting translucent parts of GTK UI appear lighter than they should because alpha is applied twice.

            mkartashev Maxim Kartashev
            mkartashev Maxim Kartashev
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: