Bug 36700

Summary: REGRESSION (r56182): iWeb shadow drawn around image rectangle, not around opaque part of the image
Product: WebKit Reporter: Jean-Luc Evrard <gratvador>
Component: CSSAssignee: Nobody <webkit-unassigned>
Severity: Normal CC: ap, bdakin, eric, mitz, simon.fraser
Priority: P1 Keywords: InRadar, NeedsReduction, Regression
Version: 528+ (Nightly build)   
Hardware: Mac (Intel)   
OS: OS X 10.6   
URL: http://john.boring.free.fr
Description Flags
two screenshots
Revert the CSSPrimitiveValue part of r56182 darin: review+

Description Jean-Luc Evrard 2010-03-27 05:57:55 PDT
Hi, in some circumstances, a frame is appearing around images in web pages created with iWeb (see URL). Safari (Mac/PC) as well as IE8 render correctly. Firefox Mac last version does not...
Curiously, the problem is only visible if the whole page is downloaded.
Comment 1 Alexey Proskuryakov 2010-03-27 11:56:12 PDT
I'm confused. If Firefox is the only browser that doesn't work correctly, why are you reporting this problem against WebKit?

Or are you saying that this doesn't work in Safari when using a nightly build of WebKit? If so, could you please attach a screenshot, to make it more clear what problem you are seeing?
Comment 2 Jean-Luc Evrard 2010-03-27 12:46:25 PDT
Created attachment 51838 [details]
two screenshots

Two screenshots of affected/unaffected rendering
Comment 3 Jean-Luc Evrard 2010-03-27 12:47:33 PDT
Safari webkit (Mac) and Firefox are affected
Safari 4 (Mac/Win) and IE8 are unaffected
Comment 4 Alexey Proskuryakov 2010-03-27 13:22:36 PDT
Thanks! Confirmed using r56587.
Comment 5 Alexey Proskuryakov 2010-03-27 13:23:01 PDT
Comment 6 mitz 2010-03-27 13:37:15 PDT
This appears to be due to a change in shadow behavior in canvas.
Comment 7 mitz 2010-03-27 14:26:17 PDT
Caused by <http://trac.webkit.org/changeset/56182>. Presumably by the change to serialization of the transparent color. Presumably the content expects rgba(0, 0, 0, 0).
Comment 8 mitz 2010-03-27 14:30:39 PDT
From …Main/Scripts/iWebImage.js:

p_alphaComponent : function(color) {
    var alpha=1.0;
    if (color && color.indexOf('rgba(') != -1) {
        if (color.match(/rgba\((?:\s*\S+\s*,\s*){3}(\S+)\s*\)/)) {
    return alpha;
Comment 9 mitz 2010-03-27 15:05:33 PDT
Created attachment 51843 [details]
Revert the CSSPrimitiveValue part of r56182
Comment 10 Darin Adler 2010-03-27 17:36:28 PDT
Comment on attachment 51843 [details]
Revert the CSSPrimitiveValue part of r56182

Comment 11 mitz 2010-03-27 18:00:16 PDT
Fixed in <http://trac.webkit.org/projects/webkit/changeset/56673>.
Comment 12 Eric Seidel (no email) 2010-03-27 18:42:20 PDT
This appears to have turned the leopard bots red.
Comment 13 Alexey Proskuryakov 2010-07-09 18:57:13 PDT
It would have been nice if there were a PASS/FAIL test for this.