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 595997 - Fix interaction of borders/background and scrolling
Fix interaction of borders/background and scrolling
Status: RESOLVED FIXED
Product: gnome-shell
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: gnome-shell-maint
gnome-shell-maint
Depends on:
Blocks:
 
 
Reported: 2009-09-22 19:19 UTC by Owen Taylor
Modified: 2009-10-01 19:32 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Remove NbtkViewport from our tree (25.16 KB, patch)
2009-09-22 19:19 UTC, Owen Taylor
none Details | Review
Fix interaction of borders/background and scrolling (8.33 KB, patch)
2009-09-22 19:20 UTC, Owen Taylor
none Details | Review
Fix interaction of borders/background and scrolling (8.28 KB, patch)
2009-09-30 00:20 UTC, Owen Taylor
committed Details | Review

Description Owen Taylor 2009-09-22 19:19:57 UTC
These two patches allow us to set a border or a background on
a NbtkBoxLayout that is being scrolled. The second patch just removes
NbtkViewport rather than fixing it for the clipping change to
NbtkScrollView, since we don't use NbtkViewport anyways.
Comment 1 Owen Taylor 2009-09-22 19:19:59 UTC
Created attachment 143742 [details] [review]
Remove NbtkViewport from our tree

NbtkBoxLayout provides the basic functionality of 2-dimensional
scrolling and we don't use NbtkViewport anywhere, so remove it.

This avoids fixing NbtkViewport up for the interaction of scrolling
and borders/padding, which would be a little involved and require
a test program for NbtkViewport to be written.
Comment 2 Owen Taylor 2009-09-22 19:20:02 UTC
Created attachment 143743 [details] [review]
Fix interaction of borders/background and scrolling

NbtkBoxLayout: Make consistent that the area scrolled and clipped
to is the content area (excluding borders and padding.) Translate
back appropriately when chaining up so that the parent background
is drawn at the right place and picking on the box (if it's reactive)
picks at the right place on the screen.

clip-to-allocation is removed from NbtkScrollView since it's just
not right - if the child has any non-moving elements, like headers or
borders, it will need to set a narrower clip. And even if the entire
child scrolls, we want to clip to an arrow that excludes the scrollbars.
Comment 3 Owen Taylor 2009-09-30 00:20:13 UTC
Created attachment 144330 [details] [review]
Fix interaction of borders/background and scrolling

StBoxLayout: Make consistent that the area scrolled and clipped
to is the content area (excluding borders and padding.) Translate
back appropriately when chaining up so that the parent background
is drawn at the right place and picking on the box (if it's reactive)
picks at the right place on the screen.

clip-to-allocation is removed from StScrollView since it's just
not right - if the child has any non-moving elements, like headers or
borders, it will need to set a narrower clip. And even if the entire
child scrolls, we want to clip to an arrow that excludes the scrollbars.
Comment 4 Colin Walters 2009-09-30 21:32:26 UTC
Review of attachment 144330 [details] [review]:

Had to think about the interaction here if someone set a clip on the actor, or in the (admittedly pathological) recursive scrolled element inside a scrolled element, but it all looks OK to me.
Comment 5 Owen Taylor 2009-10-01 19:32:54 UTC
Attachment 144330 [details] pushed as a15205e - Fix interaction of borders/background and scrolling