Remove -webkit-color-correction CSS property
authordarin@apple.com <darin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 10 Aug 2015 00:10:01 +0000 (00:10 +0000)
committerdarin@apple.com <darin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 10 Aug 2015 00:10:01 +0000 (00:10 +0000)
commitd0db87b1df2bb21df594b48ca5e21cf769075d45
treeb125a0144212af115c19228ea0426fbffe2347f0
parentc1a0c6d78d08a3595a336aede02091d0ca139523
Remove -webkit-color-correction CSS property
https://bugs.webkit.org/show_bug.cgi?id=147812

Reviewed by Maciej Stachowiak.

Source/WebCore:

Covered by existing tests.

I am doing some general cleanup of handling of color spaces in WebKit.
This removes the obsolete web-visible property that allowed clients to
get color correction on older Apple platforms where we chose not to do
it all the time for performance reasons. Currently, it has no effect on
any supported platform.

Now that this property is removed, a website can detect that it's not
there if it uses getComputedStyle, but I don't expect this to have
significant compatibility fallout. It's harmless to continue using the
property in legacy content or websites that have not been updated, since
unknown property names are ignored and it had no effect before anyway.

* css/CSSComputedStyleDeclaration.cpp: Removed
CSSPropertyWebkitColorCorrection from the list of computed properties.
(WebCore::ComputedStyleExtractor::propertyValue): Removed the
CSSPropertyWebkitColorCorrection case.

* css/CSSParser.cpp:
(WebCore::isValidKeywordPropertyAndValue): Removed the
CSSPropertyWebkitColorCorrection case.
(WebCore::isKeywordPropertyID): Ditto.
(WebCore::CSSParser::parseValue): Ditto.

* css/CSSPrimitiveValueMappings.h:
(WebCore::CSSPrimitiveValue::CSSPrimitiveValue): Deleted the overload
of this that converts a ColorSpace to a CSSPrimitiveValue.
(WebCore::CSSPrimitiveValue::operator ColorSpace): Deleted.

* css/CSSPropertyNames.in: Removed -webkit-color-correction.

* css/CSSValueKeywords.in: Removed the -webkit-color-correction section,
which contained sRGB.

* css/SVGCSSValueKeywords.in: Uncommented sRGB now that it's not shared
with -webkit-color-correction.

* rendering/style/RenderStyle.h: Removed setColorSpace and initialColorSpace.
Kept colorSpace around for now, but it simply returns ColorSpaceSRGB.
This prevents us from needing to touch every single call site that passes
the color space in to functions in the platform graphics abstraction.
We'll touch most of those call sites when we change Color to include the
color space and eventually we can delete this.

* rendering/style/StyleRareInheritedData.cpp: Deleted colorSpace.
(WebCore::StyleRareInheritedData::StyleRareInheritedData): Deleted
code to initialize colorSpace and to copy colorSpace.
(WebCore::StyleRareInheritedData::operator==): Deleted code to compare
colorSpace.

LayoutTests:

Given that -webkit-color-correction had no effect on rendering on any platform in any
configuration we covered, it's amazing how many tests we had for it.

* fast/css/getComputedStyle/computed-style-expected.txt: Removed expected results for
-webkit-color-correction property.
* fast/css/getComputedStyle/computed-style-without-renderer-expected.txt: Ditto.
* svg/css/getComputedStyle-basic-expected.txt: Ditto.

* fast/css/getComputedStyle/resources/property-names.js: Removed -webkit-color-correction.

* fast/css/color-correction-backgrounds-and-text.html: Removed.
* fast/css/color-correction-on-background-image.html: Removed.
* fast/css/color-correction-on-backgrounds.html: Removed.
* fast/css/color-correction-on-box-shadow.html: Removed.
* fast/css/color-correction-on-text-shadow.html: Removed.
* fast/css/color-correction-on-text.html: Removed.
* fast/css/color-correction-untagged-images.html: Removed.
* fast/css/color-correction.html: Removed.
* fast/css/parsing-color-correction-expected.txt: Removed.
* fast/css/parsing-color-correction.html: Removed.
* fast/css/resources/parsing-color-correction.js: Removed.
* platform/efl/fast/css/color-correction-backgrounds-and-text-expected.png: Removed.
* platform/efl/fast/css/color-correction-backgrounds-and-text-expected.txt: Removed.
* platform/efl/fast/css/color-correction-expected.png: Removed.
* platform/efl/fast/css/color-correction-expected.txt: Removed.
* platform/efl/fast/css/color-correction-on-background-image-expected.png: Removed.
* platform/efl/fast/css/color-correction-on-background-image-expected.txt: Removed.
* platform/efl/fast/css/color-correction-on-backgrounds-expected.png: Removed.
* platform/efl/fast/css/color-correction-on-backgrounds-expected.txt: Removed.
* platform/efl/fast/css/color-correction-on-box-shadow-expected.png: Removed.
* platform/efl/fast/css/color-correction-on-box-shadow-expected.txt: Removed.
* platform/efl/fast/css/color-correction-on-text-expected.png: Removed.
* platform/efl/fast/css/color-correction-on-text-expected.txt: Removed.
* platform/efl/fast/css/color-correction-on-text-shadow-expected.png: Removed.
* platform/efl/fast/css/color-correction-on-text-shadow-expected.txt: Removed.
* platform/efl/fast/css/color-correction-untagged-images-expected.png: Removed.
* platform/efl/fast/css/color-correction-untagged-images-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-backgrounds-and-text-expected.png: Removed.
* platform/gtk/fast/css/color-correction-backgrounds-and-text-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-expected.png: Removed.
* platform/gtk/fast/css/color-correction-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-on-background-image-expected.png: Removed.
* platform/gtk/fast/css/color-correction-on-background-image-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-on-backgrounds-expected.png: Removed.
* platform/gtk/fast/css/color-correction-on-backgrounds-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-on-box-shadow-expected.png: Removed.
* platform/gtk/fast/css/color-correction-on-box-shadow-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-on-text-expected.png: Removed.
* platform/gtk/fast/css/color-correction-on-text-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-on-text-shadow-expected.png: Removed.
* platform/gtk/fast/css/color-correction-on-text-shadow-expected.txt: Removed.
* platform/gtk/fast/css/color-correction-untagged-images-expected.png: Removed.
* platform/gtk/fast/css/color-correction-untagged-images-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-backgrounds-and-text-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-on-background-image-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-on-backgrounds-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-on-box-shadow-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-on-text-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-on-text-shadow-expected.txt: Removed.
* platform/ios-simulator-wk2/fast/css/color-correction-untagged-images-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-backgrounds-and-text-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-on-background-image-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-on-backgrounds-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-on-box-shadow-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-on-text-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-on-text-shadow-expected.txt: Removed.
* platform/ios-simulator/fast/css/color-correction-untagged-images-expected.txt: Removed.
* platform/mac/fast/css/color-correction-backgrounds-and-text-expected.png: Removed.
* platform/mac/fast/css/color-correction-backgrounds-and-text-expected.txt: Removed.
* platform/mac/fast/css/color-correction-expected.png: Removed.
* platform/mac/fast/css/color-correction-expected.txt: Removed.
* platform/mac/fast/css/color-correction-on-background-image-expected.png: Removed.
* platform/mac/fast/css/color-correction-on-background-image-expected.txt: Removed.
* platform/mac/fast/css/color-correction-on-backgrounds-expected.png: Removed.
* platform/mac/fast/css/color-correction-on-backgrounds-expected.txt: Removed.
* platform/mac/fast/css/color-correction-on-box-shadow-expected.png: Removed.
* platform/mac/fast/css/color-correction-on-box-shadow-expected.txt: Removed.
* platform/mac/fast/css/color-correction-on-text-expected.png: Removed.
* platform/mac/fast/css/color-correction-on-text-expected.txt: Removed.
* platform/mac/fast/css/color-correction-on-text-shadow-expected.png: Removed.
* platform/mac/fast/css/color-correction-on-text-shadow-expected.txt: Removed.
* platform/mac/fast/css/color-correction-untagged-images-expected.png: Removed.
* platform/mac/fast/css/color-correction-untagged-images-expected.txt: Removed.
* platform/win/fast/css/color-correction-backgrounds-and-text-expected.txt: Removed.
* platform/win/fast/css/color-correction-expected.txt: Removed.
* platform/win/fast/css/color-correction-on-background-image-expected.txt: Removed.
* platform/win/fast/css/color-correction-on-backgrounds-expected.txt: Removed.
* platform/win/fast/css/color-correction-on-box-shadow-expected.txt: Removed.
* platform/win/fast/css/color-correction-on-text-expected.txt: Removed.
* platform/win/fast/css/color-correction-on-text-shadow-expected.txt: Removed.
* platform/win/fast/css/color-correction-untagged-images-expected.txt: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@188202 268f45cc-cd09-0410-ab3c-d52691b4dbfc
97 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/css/color-correction-backgrounds-and-text.html [deleted file]
LayoutTests/fast/css/color-correction-on-background-image.html [deleted file]
LayoutTests/fast/css/color-correction-on-backgrounds.html [deleted file]
LayoutTests/fast/css/color-correction-on-box-shadow.html [deleted file]
LayoutTests/fast/css/color-correction-on-text-shadow.html [deleted file]
LayoutTests/fast/css/color-correction-on-text.html [deleted file]
LayoutTests/fast/css/color-correction-untagged-images.html [deleted file]
LayoutTests/fast/css/color-correction.html [deleted file]
LayoutTests/fast/css/getComputedStyle/computed-style-expected.txt
LayoutTests/fast/css/getComputedStyle/computed-style-without-renderer-expected.txt
LayoutTests/fast/css/getComputedStyle/resources/property-names.js
LayoutTests/fast/css/parsing-color-correction-expected.txt [deleted file]
LayoutTests/fast/css/parsing-color-correction.html [deleted file]
LayoutTests/fast/css/resources/parsing-color-correction.js [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-backgrounds-and-text-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-backgrounds-and-text-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-background-image-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-background-image-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-backgrounds-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-backgrounds-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-box-shadow-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-box-shadow-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-text-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-text-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-text-shadow-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-on-text-shadow-expected.txt [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-untagged-images-expected.png [deleted file]
LayoutTests/platform/efl/fast/css/color-correction-untagged-images-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-backgrounds-and-text-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-backgrounds-and-text-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-background-image-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-background-image-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-backgrounds-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-backgrounds-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-box-shadow-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-box-shadow-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-text-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-text-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-text-shadow-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-on-text-shadow-expected.txt [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-untagged-images-expected.png [deleted file]
LayoutTests/platform/gtk/fast/css/color-correction-untagged-images-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-backgrounds-and-text-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-on-background-image-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-on-backgrounds-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-on-box-shadow-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-on-text-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-on-text-shadow-expected.txt [deleted file]
LayoutTests/platform/ios-simulator-wk2/fast/css/color-correction-untagged-images-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-backgrounds-and-text-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-on-background-image-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-on-backgrounds-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-on-box-shadow-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-on-text-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-on-text-shadow-expected.txt [deleted file]
LayoutTests/platform/ios-simulator/fast/css/color-correction-untagged-images-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-backgrounds-and-text-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-backgrounds-and-text-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-background-image-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-background-image-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-backgrounds-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-backgrounds-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-box-shadow-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-box-shadow-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-text-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-text-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-text-shadow-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-on-text-shadow-expected.txt [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-untagged-images-expected.png [deleted file]
LayoutTests/platform/mac/fast/css/color-correction-untagged-images-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-backgrounds-and-text-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-on-background-image-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-on-backgrounds-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-on-box-shadow-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-on-text-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-on-text-shadow-expected.txt [deleted file]
LayoutTests/platform/win/fast/css/color-correction-untagged-images-expected.txt [deleted file]
LayoutTests/svg/css/getComputedStyle-basic-expected.txt
Source/WebCore/ChangeLog
Source/WebCore/css/CSSComputedStyleDeclaration.cpp
Source/WebCore/css/CSSParser.cpp
Source/WebCore/css/CSSPrimitiveValueMappings.h
Source/WebCore/css/CSSPropertyNames.in
Source/WebCore/css/CSSValueKeywords.in
Source/WebCore/css/SVGCSSValueKeywords.in
Source/WebCore/rendering/style/RenderStyle.h
Source/WebCore/rendering/style/StyleRareInheritedData.cpp