WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED INVALID
144710
Scroll-snap point produces strange 'default' snap offset vector
https://bugs.webkit.org/show_bug.cgi?id=144710
Summary
Scroll-snap point produces strange 'default' snap offset vector
Brent Fulgham
Reported
2015-05-06 14:25:19 PDT
When we have scroll-snap point markup that specifies a horizontal snap range, but not a vertical, we get a default value of "{0, 15}". Example: .horizontalGallery { width: 300px; height: 300px; overflow-y: hidden; overflow-x: auto; -webkit-overflow-scrolling: touch; -webkit-scroll-snap-points-x: repeat(100%); -webkit-scroll-snap-type: mandatory; } This produces snap points as follows: horizontal = { 0, 300, 600, 900, 1200, 1500 }, vertical = { 0, 15 } I would expect to see either no snap points, or snap points for the two scroll extrema (i.e., vertical = { 0, 1500 }
Attachments
Screenshot showing horizontal scrollbar
(5.64 KB, image/png)
2015-05-06 15:53 PDT
,
Brent Fulgham
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Brent Fulgham
Comment 1
2015-05-06 14:29:17 PDT
We enter the 'updateFromStyle' helper function in AxisScrollSnapOffsets.cpp with no vertical offset values. These are being set as the default positions: 1. We always append 0 when we have a scrollable area. 2. We always append the value of 'scroll{Width|Height}' - 'view{Width|Height}' In the test case 'scroll-snap-coordinates-borders.html', we somehow have a scrollable area that is 15 pixels larger than the view area. Could this be due to scrollbars?
Brent Fulgham
Comment 2
2015-05-06 15:52:30 PDT
Measuring the pixels on a screenshot shows that the horizontal scrollbar is 15 pixels high, which is why we appear to have a vertical scrollable area of 15 pixels. I think this is working correctly.
Brent Fulgham
Comment 3
2015-05-06 15:53:05 PDT
Created
attachment 252534
[details]
Screenshot showing horizontal scrollbar
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug