https://bugs.kde.org/show_bug.cgi?id=438185

            Bug ID: 438185
           Summary: In GTK3 apps, checked toggle buttons in inactive
                    windows have black text on blue backgrounds
           Product: Breeze
           Version: 5.21.90
          Platform: Other
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: gtk theme
          Assignee: uhh...@gmail.com
          Reporter: nyanpas...@tuta.io
                CC: plasma-b...@kde.org
  Target Milestone: ---

SUMMARY
In GTK3 apps, if you enable a toggle button (so it turns blue), then focus a
different window, the button remains blue (whereas a tab-focused button would
turn white), but the text turns black (which only looks right if the background
turns white).

STEPS TO REPRODUCE
1. With the GTK3 theme set to Breeze, run gtk3-widget-factory.
2. Press Super to open the start menu and unfocus the new window.

OBSERVED RESULT
The third "togglebutton" visible has black text on a blue background.

EXPECTED RESULT
It's... complicated.

Checked toggle buttons in backdrop windows use
@theme_button_foreground_active_backdrop_breeze for text, and
@theme_button_decoration_focus_backdrop_breeze for background. In practice,
this results in black text on a blue background.

Strangely, @theme_button_foreground_active_backdrop_breeze is actually white
(#fcfcfc) in the /usr/share/themes/Breeze/gtk-3.0/gtk.css generated when
building breeze-gtk from /usr/share/color-schemes/Breeze.colors, but black
(#232627) in the ~/.config/gtk-3.0/colors.css generated by kde-gtk-config when
you switch KDE color schemes to Breeze.colors (results may deviate slightly if
you're using Breeze Light). This is an inconsistency that probably should be
resolved.

I don't know how to best resolve this inconsistency, since neither
@theme_button_foreground_active_backdrop_breeze nor
@theme_button_decoration_focus_backdrop_breeze are never used for their
"intended" purposes of styling focused widgets in a background window. This is
because a focused button in a backdrop (unfocused) window actually lacks the
:active pseudo-class which indicates a focused button in a foreground window!
(Coincidentally, this is a good thing because it causes breeze-gtk to match
breeze-qt, since neither highlights focused widgets in unfocused windows.)

Additionally, merely fixing the colors of these 2 variables won't fix GTK
toggle buttons to resemble Qt's styling of checkable buttons, because Breeze Qt
checkable buttons don't use the blue "focused" color when checked, but "gray"
instead!

SOFTWARE/OS VERSIONS
Operating System: Arch Linux
KDE Plasma Version: 5.22.80
KDE Frameworks Version: 5.82.0
Qt Version: 5.15.2
Kernel Version: 5.12.9-arch1-1 (64-bit)
Graphics Platform: X11
Processors: 12 × AMD Ryzen 5 5600X 6-Core Processor
Memory: 15.6 GiB of RAM
Graphics Processor: NVIDIA GeForce GT 730/PCIe/SSE2

ADDITIONAL INFORMATION

Unfortunately, Breeze Qt's styling of checkable buttons is flawed as well: If
you focus a checkable button (eg. the mute/etc. icon buttons in pavucontrol-qt)
by pressing Tab (clicking doesn't work), then the checked/unchecked toggle
states of the button are indistinguishable in Breeze except for a shift by 1
pixel down/right when checked. Perhaps the checked+focused state should be
changed to have a dark blue focus border, plus a gray background to indicate
"checked". (I don't know if the Plasma 5.23 Breeze redesign will obsolete this
corner case, or if this needs to be taken into account when redesigning Breeze
to prevent this issue from recurring.)

Breeze GTK3 is worse: unlike Breeze Qt, clicking on a checkable button focuses
it (resulting in a blue background, turning light blue when clicked). Worse
yet, the checked and unchecked states are entirely indistinguishable (since the
button doesn't move when checked and unchecked).

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to