Skip to content

Achieve WCAG AA text contrast for labels using opacity

Part of plasma-desktop#149

Right now we use opacity to reduce the visual intensity of subtitle labels. We tend to use nonstandard opacity levels, and the levels we do use never achieve WCAG AA, which specifies a text contrast of at least 4.5:1.

Standardizing on an opacity level of 0.75 raises the text contrast of all these labels to:

  • 5.73:1 on the opaque gray window background color
  • 5.44:1 on a translucent background in Plasma with the current default wallpaper (though this will vary a bit with different backgrounds)

Now they meet WCAG AA.

Merge request reports

Loading