diff --git a/gfx/src/thebes/nsThebesImage.cpp b/gfx/src/thebes/nsThebesImage.cpp index f65bcfcc88d0..bbef8cef1d08 100644 --- a/gfx/src/thebes/nsThebesImage.cpp +++ b/gfx/src/thebes/nsThebesImage.cpp @@ -533,21 +533,26 @@ nsThebesImage::Draw(nsIRenderingContext &aContext, pat->SetMatrix(mat); - // XXX bug 324698 -#ifndef XP_MACOSX - if (xscale > 1.0 || yscale > 1.0) { + if (xscale != 1.0 || yscale != 1.0) { +#if !defined(XP_MACOSX) && !defined(XP_WIN) // See bug 324698. This is a workaround. // // Set the filter to CAIRO_FILTER_FAST if we're scaling up -- otherwise, // pixman's sampling will sample transparency for the outside edges and we'll - // get blurry edges. CAIRO_EXTEND_PAD would also work here, but it's not - // implemented for image sources. + // get blurry edges. CAIRO_EXTEND_PAD would also work here, if + // available // // This effectively disables smooth upscaling for images. pat->SetFilter(0); - } #endif +#if defined(XP_WIN) + // turn on EXTEND_PAD only for win32, and only when scaling; + // it's not implemented correctly on linux in the X server. + pat->SetExtend(gfxPattern::EXTEND_PAD); +#endif + } + ctx->NewPath(); ctx->SetPattern(pat); ctx->Rectangle(destRect); diff --git a/layout/reftests/bugs/234686-1.gif b/layout/reftests/bugs/234686-1.gif index 43cf6cc05b31..ed10d8a70579 100644 Binary files a/layout/reftests/bugs/234686-1.gif and b/layout/reftests/bugs/234686-1.gif differ diff --git a/layout/reftests/bugs/234686-10.gif b/layout/reftests/bugs/234686-10.gif index 491183699e0c..4b24f565f37a 100644 Binary files a/layout/reftests/bugs/234686-10.gif and b/layout/reftests/bugs/234686-10.gif differ diff --git a/layout/reftests/bugs/234686-11.gif b/layout/reftests/bugs/234686-11.gif index acf40cd71c3d..effaaee27df2 100644 Binary files a/layout/reftests/bugs/234686-11.gif and b/layout/reftests/bugs/234686-11.gif differ diff --git a/layout/reftests/bugs/234686-12.gif b/layout/reftests/bugs/234686-12.gif index 0604d430a071..c4c8d24f45f6 100644 Binary files a/layout/reftests/bugs/234686-12.gif and b/layout/reftests/bugs/234686-12.gif differ diff --git a/layout/reftests/bugs/234686-13.gif b/layout/reftests/bugs/234686-13.gif index acf40cd71c3d..effaaee27df2 100644 Binary files a/layout/reftests/bugs/234686-13.gif and b/layout/reftests/bugs/234686-13.gif differ diff --git a/layout/reftests/bugs/234686-14.gif b/layout/reftests/bugs/234686-14.gif index d50d7ae12cce..04cc507d2e31 100644 Binary files a/layout/reftests/bugs/234686-14.gif and b/layout/reftests/bugs/234686-14.gif differ diff --git a/layout/reftests/bugs/234686-15.gif b/layout/reftests/bugs/234686-15.gif index 5223b02e5199..04cc507d2e31 100644 Binary files a/layout/reftests/bugs/234686-15.gif and b/layout/reftests/bugs/234686-15.gif differ diff --git a/layout/reftests/bugs/234686-16.gif b/layout/reftests/bugs/234686-16.gif index d50d7ae12cce..04cc507d2e31 100644 Binary files a/layout/reftests/bugs/234686-16.gif and b/layout/reftests/bugs/234686-16.gif differ diff --git a/layout/reftests/bugs/234686-17.gif b/layout/reftests/bugs/234686-17.gif index dc7651c13306..b06554621eba 100644 Binary files a/layout/reftests/bugs/234686-17.gif and b/layout/reftests/bugs/234686-17.gif differ diff --git a/layout/reftests/bugs/234686-18.gif b/layout/reftests/bugs/234686-18.gif index c19e7f6c8349..970a23fb5098 100644 Binary files a/layout/reftests/bugs/234686-18.gif and b/layout/reftests/bugs/234686-18.gif differ diff --git a/layout/reftests/bugs/234686-19.gif b/layout/reftests/bugs/234686-19.gif index 5595947c8262..b06554621eba 100644 Binary files a/layout/reftests/bugs/234686-19.gif and b/layout/reftests/bugs/234686-19.gif differ diff --git a/layout/reftests/bugs/234686-2.gif b/layout/reftests/bugs/234686-2.gif index deead66ac076..98153d4d38df 100644 Binary files a/layout/reftests/bugs/234686-2.gif and b/layout/reftests/bugs/234686-2.gif differ diff --git a/layout/reftests/bugs/234686-3.gif b/layout/reftests/bugs/234686-3.gif index bc766fa906f7..98153d4d38df 100644 Binary files a/layout/reftests/bugs/234686-3.gif and b/layout/reftests/bugs/234686-3.gif differ diff --git a/layout/reftests/bugs/234686-4.gif b/layout/reftests/bugs/234686-4.gif index d50d7ae12cce..04cc507d2e31 100644 Binary files a/layout/reftests/bugs/234686-4.gif and b/layout/reftests/bugs/234686-4.gif differ diff --git a/layout/reftests/bugs/234686-5.gif b/layout/reftests/bugs/234686-5.gif index dc7651c13306..b06554621eba 100644 Binary files a/layout/reftests/bugs/234686-5.gif and b/layout/reftests/bugs/234686-5.gif differ diff --git a/layout/reftests/bugs/234686-6.gif b/layout/reftests/bugs/234686-6.gif index deead66ac076..98153d4d38df 100644 Binary files a/layout/reftests/bugs/234686-6.gif and b/layout/reftests/bugs/234686-6.gif differ diff --git a/layout/reftests/bugs/234686-7.gif b/layout/reftests/bugs/234686-7.gif index fe813c1323d3..c4c8d24f45f6 100644 Binary files a/layout/reftests/bugs/234686-7.gif and b/layout/reftests/bugs/234686-7.gif differ diff --git a/layout/reftests/bugs/234686-8.gif b/layout/reftests/bugs/234686-8.gif index d50d7ae12cce..04cc507d2e31 100644 Binary files a/layout/reftests/bugs/234686-8.gif and b/layout/reftests/bugs/234686-8.gif differ diff --git a/layout/reftests/bugs/234686-9.gif b/layout/reftests/bugs/234686-9.gif index 5223b02e5199..04cc507d2e31 100644 Binary files a/layout/reftests/bugs/234686-9.gif and b/layout/reftests/bugs/234686-9.gif differ diff --git a/layout/reftests/bugs/234686-ref.gif b/layout/reftests/bugs/234686-ref.gif index 43cf6cc05b31..ed10d8a70579 100644 Binary files a/layout/reftests/bugs/234686-ref.gif and b/layout/reftests/bugs/234686-ref.gif differ diff --git a/layout/reftests/bugs/reftest.list b/layout/reftests/bugs/reftest.list index 215618da9129..ae8ed3d3dcf1 100644 --- a/layout/reftests/bugs/reftest.list +++ b/layout/reftests/bugs/reftest.list @@ -128,22 +128,22 @@ fails == 134706-6b.html 134706-6b-ref.html # bug 363248 (via bug 414193, anyway) == 234686-1.html 234686-ref.html == 234686-2.html 234686-ref.html == 234686-3.html 234686-ref.html -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-4.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-5.html 234686-ref.html # bug 371316 or other image scaling issue +== 234686-4.html 234686-ref.html +== 234686-5.html 234686-ref.html == 234686-6.html 234686-ref.html == 234686-7.html 234686-ref.html -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-8.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-9.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-10.html 234686-ref.html # bug 371316 or other image scaling issue +== 234686-8.html 234686-ref.html +== 234686-9.html 234686-ref.html +== 234686-10.html 234686-ref.html == 234686-11.html 234686-ref.html -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-12.html 234686-ref.html # bug 371316 or other image scaling issue +== 234686-12.html 234686-ref.html == 234686-13.html 234686-ref.html -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-14.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-15.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-16.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-17.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-18.html 234686-ref.html # bug 371316 or other image scaling issue -fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 234686-19.html 234686-ref.html # bug 371316 or other image scaling issue +== 234686-14.html 234686-ref.html +== 234686-15.html 234686-ref.html +== 234686-16.html 234686-ref.html +== 234686-17.html 234686-ref.html +== 234686-18.html 234686-ref.html +== 234686-19.html 234686-ref.html == 234964-1.html 234964-1-ref.html == 234964-2.html 234964-2-ref.html == 235593-1.html 235593-1-ref.html