After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 727211 - W32: Selection background color applies to check/radio marks
W32: Selection background color applies to check/radio marks
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: Themes
unspecified
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2014-03-28 06:13 UTC by LRN
Modified: 2014-04-04 10:22 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
W32: Remove selection from check/radio marks (1.28 KB, patch)
2014-03-28 06:13 UTC, LRN
committed Details | Review
How it looks without the patch (1.08 KB, image/png)
2014-03-28 06:15 UTC, LRN
  Details

Description LRN 2014-03-28 06:13:21 UTC
When you activate, say, a checkbutton, it briefly becomes "selected", and gets
the appropriate "selected" background color (on W32 that's a shade of blue).
This is abnormal.

The way you activate does influence the display. If you hover your mouse over it
and activate via changing the keyboard focus and pressing <space>, the whole checkbutton
gets selected (which is also abnormal, but at least it doesn't look ugly).
If you do the same, but leave the mouse cursor outside the checkbutton, you get
selection applied only to the checkmark (which is abnormal AND ugly).

The reason, i believe, why this is happening is this style in gtk-win32-base.css:

> *:selected,
> *:selected:focus {
>     background-color: @selected_bg_color;
>     color: @selected_fg_color;
> }

Now, there may be a good case to be made for not using such blanket styles
(as someone on StackOverflow pointed out, they aren't called "Cascading"
Style Sheets for nothing: style inheritance is a feature, and should be used
consciously and not fought against), but unless someone volunteers for the job,
i'd rather just make a quick fix for the issue at hand by overriding the
selected style for check/radio marks.
Comment 1 LRN 2014-03-28 06:13:38 UTC
Created attachment 273134 [details] [review]
W32: Remove selection from check/radio marks

Current theme allows selection to leak into check/radio marks,
resulting in ugly colored rectangles showing up underneath the marks.
Comment 2 LRN 2014-03-28 06:15:37 UTC
Created attachment 273135 [details]
How it looks without the patch

This is how it looks. Patching removes (makes transparent) the blue background, over which w32 checkmark is painted. It's easy to imagine, so i'm not attaching the "How it looks with the patch" image.
Comment 3 Matthias Clasen 2014-03-28 18:58:54 UTC
Review of attachment 273134 [details] [review]:

ok
Comment 4 LRN 2014-04-04 10:22:54 UTC
Attachment 273134 [details] pushed as d83b127 - W32: Remove selection from check/radio marks