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 644777 - range: allow stepper-spacing > 0 and trough-under-steppers = TRUE
range: allow stepper-spacing > 0 and trough-under-steppers = TRUE
Status: RESOLVED FIXED
Product: gtk+
Classification: Platform
Component: .General
unspecified
Other All
: Normal normal
: ---
Assigned To: gtk-bugs
gtk-bugs
Depends on:
Blocks:
 
 
Reported: 2011-03-14 23:44 UTC by Cosimo Cecchi
Modified: 2011-03-16 17:19 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
range: allow stepper-spacing > 0 and trough-under-steppers = TRUE (3.25 KB, patch)
2011-03-14 23:44 UTC, Cosimo Cecchi
committed Details | Review

Description Cosimo Cecchi 2011-03-14 23:44:16 UTC
The rationale is in the commit message to the attached patch.
Comment 1 Cosimo Cecchi 2011-03-14 23:44:41 UTC
Created attachment 183394 [details] [review]
range: allow stepper-spacing > 0 and trough-under-steppers = TRUE

Commit 4bb3d6441439e4d99255a3a08b39da7100ced953 introduced a limitation
to GtkRange style properties; when stepper-spacing is > 0,
trough-under-steppers is automatically set to FALSE; this means that
setting a spacing between the steppers (e.g. the scrollbar buttons) and
the trough (i.e. the area over which the slider is free to move) would
make the buttons always get the full allocation on the !orientation
direction.
The rationale is without this limitation, you would get an area which
seems clickable, but it's actually not.

While this is true, and undesirable, for big stepper spacings, themes
that use trough-under-steppers (which is TRUE by default anyway),
might want to set smaller spacings to avoid drawing a double line between
the button and the slider borders.

To add confusion, the documentation got it flipped, i.e. it stated
setting a positive stepper-spacing would set trough-under-steppers to
TRUE (which would also make the behavior expected by commit
4bb3d6441439e4d99255a3a08b39da7100ced953 impossible).

I don't think hardcoding either of the two limitations is a good thing.
We should let themes handle this instead, and remove this limitation. If
you want the old behavior, you can manually set trough-under-steppers to
FALSE if you set a positive stepper-spacing in your theme.
Comment 2 Cosimo Cecchi 2011-03-16 17:19:49 UTC
Attachment 183394 [details] pushed as c96057e - range: allow stepper-spacing > 0 and trough-under-steppers = TRUE