Respect image-rendering setting for determing image-rendering quality
authorallan.jensen@digia.com <allan.jensen@digia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 23 Apr 2013 08:17:05 +0000 (08:17 +0000)
committerallan.jensen@digia.com <allan.jensen@digia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 23 Apr 2013 08:17:05 +0000 (08:17 +0000)
commit27e1390a7b035adeb1c7a3b24b40571f7d304e9c
tree210572a1b0ff87a976666d2cb803c43009112505
parentc44530a4dd95ddd339d8f1e5ba52cdcbcecb73f3
Respect image-rendering setting for determing image-rendering quality
https://bugs.webkit.org/show_bug.cgi?id=113405

Reviewed by Benjamin Poulain.

Source/WebCore:

Remove the CSS4 values as they are not ready for implementation yet.
We still parse the -webkit-crisp-edges and SVG compatibility values to
be closer to the the partial support in Gecko and Presto.

Tests: fast/css/image-rendering-canvas.html
       fast/css/image-rendering-parsing.html
       fast/css/image-rendering.html
       fast/css/optimize-contrast-image.html

* css/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue):
* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator EImageRendering):
* css/CSSValueKeywords.in:
* css/SVGCSSParser.cpp:
(WebCore::CSSParser::parseSVGValue):
* rendering/RenderBoxModelObject.cpp:
(WebCore::ImageQualityController::shouldPaintAtLowQuality):
* rendering/RenderHTMLCanvas.cpp:
(WebCore::RenderHTMLCanvas::paintReplaced):
* rendering/style/RenderStyleConstants.h:

Tools:

Remove CSS4 Images option. It is not ready for implementation.

* Scripts/webkitperl/FeatureList.pm:

LayoutTests:

Moved the two tests of image-rendering out of CSS3 since it was removed from the final recommendation.
Added tests of the supported values, and upgraded one test to a reference test so that it now tests
that -webkit-optimize-contrast gets converted to and treated as -webkit-crisp-edges.

Baselines for fast/css/image-rendering.html will be uploaded later when the bots have generated them.

* css3/images/optimize-contrast-image-expected.png: Removed.
* css3/images/optimize-contrast-image-expected.txt: Removed.
* fast/css/image-rendering-canvas-expected.png: Renamed from LayoutTests/css3/images/optimize-contrast-canvas-expected.png.
* fast/css/image-rendering-canvas-expected.txt: Renamed from LayoutTests/css3/images/optimize-contrast-canvas-expected.txt.
* fast/css/image-rendering-canvas.html: Renamed from LayoutTests/css3/images/optimize-contrast-canvas.html.
* fast/css/image-rendering-expected.txt: Added.
* fast/css/image-rendering-parsing-expected.txt: Added.
* fast/css/image-rendering-parsing.html: Renamed from LayoutTests/fast/css/image-set-parsing.html.
* fast/css/image-rendering.html: Added.
* fast/css/optimize-contrast-image-expected.html: Added.
* fast/css/optimize-contrast-image.html: Renamed from LayoutTests/css3/images/optimize-contrast-image.html.
* fast/css/script-tests/image-rendering-parsing.js: Added.
(testImageRendering):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@148949 268f45cc-cd09-0410-ab3c-d52691b4dbfc
24 files changed:
LayoutTests/ChangeLog
LayoutTests/css3/images/optimize-contrast-image-expected.png [deleted file]
LayoutTests/css3/images/optimize-contrast-image-expected.txt [deleted file]
LayoutTests/css3/images/optimize-contrast-image.html [deleted file]
LayoutTests/fast/css/image-rendering-canvas-expected.png [moved from LayoutTests/css3/images/optimize-contrast-canvas-expected.png with 100% similarity]
LayoutTests/fast/css/image-rendering-canvas-expected.txt [moved from LayoutTests/css3/images/optimize-contrast-canvas-expected.txt with 100% similarity]
LayoutTests/fast/css/image-rendering-canvas.html [moved from LayoutTests/css3/images/optimize-contrast-canvas.html with 56% similarity]
LayoutTests/fast/css/image-rendering-expected.txt [new file with mode: 0644]
LayoutTests/fast/css/image-rendering-parsing-expected.txt [new file with mode: 0644]
LayoutTests/fast/css/image-rendering-parsing.html [new file with mode: 0644]
LayoutTests/fast/css/image-rendering.html [new file with mode: 0644]
LayoutTests/fast/css/optimize-contrast-image-expected.html [new file with mode: 0644]
LayoutTests/fast/css/optimize-contrast-image.html [new file with mode: 0644]
LayoutTests/fast/css/script-tests/image-rendering-parsing.js [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/css/CSSParser.cpp
Source/WebCore/css/CSSPrimitiveValueMappings.h
Source/WebCore/css/CSSValueKeywords.in
Source/WebCore/css/SVGCSSParser.cpp
Source/WebCore/rendering/RenderBoxModelObject.cpp
Source/WebCore/rendering/RenderHTMLCanvas.cpp
Source/WebCore/rendering/style/RenderStyleConstants.h
Tools/ChangeLog
Tools/Scripts/webkitperl/FeatureList.pm