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 727022 - W32: Both inc- and dec-buttons on GtkSpinbutton are "inc"
W32: Both inc- and dec-buttons on GtkSpinbutton are "inc"
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-25 15:19 UTC by LRN
Modified: 2014-04-04 10:01 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix W32 theme for spinbuttons (3.20 KB, patch)
2014-03-25 15:19 UTC, LRN
reviewed Details | Review
How it looks without the patch (499 bytes, image/png)
2014-03-25 15:20 UTC, LRN
  Details
How it looks with the patch (779 bytes, image/png)
2014-03-25 15:20 UTC, LRN
  Details
Fix W32 theme for spinbuttons (v2) (3.39 KB, patch)
2014-03-25 15:52 UTC, LRN
none Details | Review
Fix W32 theme for spinbuttons (v3) (6.58 KB, patch)
2014-03-25 16:12 UTC, LRN
committed Details | Review

Description LRN 2014-03-25 15:19:27 UTC
This seems to be because "dec" button no longer selects as "bottom".
Comment 1 LRN 2014-03-25 15:19:31 UTC
Created attachment 272860 [details] [review]
Fix W32 theme for spinbuttons

It seems that the dec-button no longer has a "bottom" selector-thingy to
select for. Use "last-child" instead.
Comment 2 LRN 2014-03-25 15:20:21 UTC
Created attachment 272861 [details]
How it looks without the patch
Comment 3 LRN 2014-03-25 15:20:41 UTC
Created attachment 272862 [details]
How it looks with the patch
Comment 4 Emmanuele Bassi (:ebassi) 2014-03-25 15:24:24 UTC
Review of attachment 272860 [details] [review]:

in principle it looks good, but I wonder if you tested with right-to-left locales, and see if it still matches, or we need to add a `dir(rtl)` selector.
Comment 5 LRN 2014-03-25 15:38:17 UTC
Ah, actually, it doesn't work. It works for horizontally-oriented spinbuttons, but buttons meaning is reversed for vertically-oriented ones. And i haven't got a clue about RTL.
Comment 6 LRN 2014-03-25 15:52:14 UTC
Created attachment 272864 [details] [review]
Fix W32 theme for spinbuttons (v2)

It seems that the dec-button no longer has a "bottom" selector-thingy to
select for. Use "last-child" instead.
Use .vertical to style vertical instance differently, as last-child/first-child
meaning is inverted there.
Increase (towards 0) margins a bit, to avoid clipping the pre-light rectangle.
Comment 7 LRN 2014-03-25 16:03:22 UTC
Yep, it doesn't work with RTL.

Actually, vertical ones, which i've just fixed up, do work with RTL, since RTL doesn't change anything for them - "inc" is always first-child, "dec" is always last-child, entry is in the middle.
for horizontal ones, "last-child" is, apparently, the entry, so both buttons are styled as "dec".
Comment 8 LRN 2014-03-25 16:12:06 UTC
Created attachment 272865 [details] [review]
Fix W32 theme for spinbuttons (v3)

It seems that the dec-button no longer has a "bottom" selector-thingy to
select for. Use "last-child" instead.
Use .vertical to style vertical instance differently, as last-child/first-child
meaning is inverted there.
Increase (towards 0) margins a bit, to avoid clipping the pre-light rectangle.
Use dir(rtl) selector to style horizontal instance differently for RTL locales,
where first-child is "inc".
Comment 9 LRN 2014-04-04 10:01:46 UTC
Attachment 272865 [details] pushed as ce9437d - Fix W32 theme for spinbuttons