WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
156817
position:fixed and background-color lead to painting artifacts on non-retina displays
https://bugs.webkit.org/show_bug.cgi?id=156817
Summary
position:fixed and background-color lead to painting artifacts on non-retina ...
Trevor Rundell
Reported
2016-04-20 16:14:37 PDT
This bug is a little finicky and doesn't manifest consistently. However, the setup in this JSFiddle (
https://jsfiddle.net/Lcu6Lrv9/7/
) seems to reproduce it fairly reliably. We have three dom elements: a container which is styled with 'position: fixed', a box with a background color, and a div with a background image that is scaled / positioned to be centered within our box. Often the background color of the box element that is *outside* of the bounding box of the image is colored incorrectly. The incorrect color seems to be a function of the original background color (e.g if our background color is blue the buggy color is orange). I've reproduced this using a background-image, an <img> tag, and with an inline SVG (though it seems to happen most consistently with the setup above.) I have also reproduced this bug with PNGs and SVGs so I don't think it's related to the image type. The most important aspect seems to be that the top level container element has 'positioned: fixed'. This bug *only* manifests on non-retina displays. I have never reproduced it on a retina display. Usually opening the inspector or dragging the window around or anything that might cause a repaint causes the weird background color to fix itself. The only workaround I have found so far is to use a pre-scaled image that is larger that the box element with transparent background, rather than scaling the image with CSS.
Attachments
The bug in a JSFiddle
(70.06 KB, image/png)
2016-04-20 16:15 PDT
,
Trevor Rundell
no flags
Details
View All
Add attachment
proposed patch, testcase, etc.
Trevor Rundell
Comment 1
2016-04-20 16:15:31 PDT
Created
attachment 276862
[details]
The bug in a JSFiddle
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