Diff
Modified: trunk/LayoutTests/imported/w3c/ChangeLog (291108 => 291109)
--- trunk/LayoutTests/imported/w3c/ChangeLog 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/LayoutTests/imported/w3c/ChangeLog 2022-03-10 15:57:15 UTC (rev 291109)
@@ -1,3 +1,15 @@
+2022-03-10 Antoine Quint <[email protected]>
+
+ [web-animations] font-variant-east-asian should support discrete animation
+ https://bugs.webkit.org/show_bug.cgi?id=237665
+
+ Reviewed by Myles C. Maxfield.
+
+ * web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt:
+ * web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt:
+ * web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt:
+ * web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt:
+
2022-03-10 Lauro Moura <[email protected]>
Add context.roundRect support to OffScreenCanvas
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt (291108 => 291109)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt 2022-03-10 15:57:15 UTC (rev 291109)
@@ -13,7 +13,7 @@
FAIL Animation of font-synthesis-weight in ::marker assert_true: font-synthesis-weight doesn't seem to be supported in the computed style expected true got false
FAIL Animation of font-variant in ::marker assert_equals: expected "small-caps" but got "tabular-nums"
FAIL Animation of font-variant-caps in ::marker assert_equals: expected "small-caps" but got "normal"
-FAIL Animation of font-variant-east-asian in ::marker assert_equals: expected "full-width" but got "normal"
+PASS Animation of font-variant-east-asian in ::marker
FAIL Animation of font-variant-ligatures in ::marker assert_equals: expected "historical-ligatures" but got "normal"
FAIL Animation of font-variant-numeric in ::marker assert_equals: expected "slashed-zero" but got "tabular-nums"
FAIL Animation of font-variant-position in ::marker assert_equals: expected "sub" but got "normal"
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt (291108 => 291109)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt 2022-03-10 15:57:15 UTC (rev 291109)
@@ -257,6 +257,9 @@
PASS font-variant-alternates (type: discrete) has testAccumulation function
FAIL font-variant-alternates: "stylistic(unknown)" onto "swash(unknown)" assert_equals: The value should be stylistic(unknown) at 0ms expected "stylistic(unknown)" but got "normal"
FAIL font-variant-alternates: "swash(unknown)" onto "stylistic(unknown)" assert_equals: The value should be swash(unknown) at 0ms expected "swash(unknown)" but got "normal"
+PASS font-variant-east-asian (type: discrete) has testAccumulation function
+PASS font-variant-east-asian: "proportional-width" onto "full-width"
+PASS font-variant-east-asian: "full-width" onto "proportional-width"
PASS font-variation-settings (type: fontVariationSettings) has testAccumulation function
FAIL font-variation-settings with composite type accumulate assert_equals: The value should be "wght" 2.2 at 250ms expected "\"wght\" 2.2" but got "\"wght\" 1.2"
PASS font-variation-settings (type: discrete) has testAccumulation function
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt (291108 => 291109)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt 2022-03-10 15:57:15 UTC (rev 291109)
@@ -257,6 +257,9 @@
PASS font-variant-alternates (type: discrete) has testAddition function
FAIL font-variant-alternates: "stylistic(unknown)" onto "swash(unknown)" assert_equals: The value should be stylistic(unknown) at 0ms expected "stylistic(unknown)" but got "normal"
FAIL font-variant-alternates: "swash(unknown)" onto "stylistic(unknown)" assert_equals: The value should be swash(unknown) at 0ms expected "swash(unknown)" but got "normal"
+PASS font-variant-east-asian (type: discrete) has testAddition function
+PASS font-variant-east-asian: "proportional-width" onto "full-width"
+PASS font-variant-east-asian: "full-width" onto "proportional-width"
PASS font-variation-settings (type: fontVariationSettings) has testAddition function
FAIL font-variation-settings with composite type add assert_equals: The value should be "wght" 2.2 at 250ms expected "\"wght\" 2.2" but got "\"wght\" 1.2"
PASS font-variation-settings (type: discrete) has testAddition function
Modified: trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt (291108 => 291109)
--- trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt 2022-03-10 15:57:15 UTC (rev 291109)
@@ -313,6 +313,10 @@
FAIL font-variant-alternates uses discrete animation when animating between "swash(unknown)" and "stylistic(unknown)" with linear easing assert_equals: The value should be swash(unknown) at 0ms expected "swash(unknown)" but got "normal"
FAIL font-variant-alternates uses discrete animation when animating between "swash(unknown)" and "stylistic(unknown)" with effect easing assert_equals: The value should be swash(unknown) at 0ms expected "swash(unknown)" but got "normal"
FAIL font-variant-alternates uses discrete animation when animating between "swash(unknown)" and "stylistic(unknown)" with keyframe easing assert_equals: The value should be swash(unknown) at 0ms expected "swash(unknown)" but got "normal"
+PASS font-variant-east-asian (type: discrete) has testInterpolation function
+PASS font-variant-east-asian uses discrete animation when animating between "full-width" and "proportional-width" with linear easing
+PASS font-variant-east-asian uses discrete animation when animating between "full-width" and "proportional-width" with effect easing
+PASS font-variant-east-asian uses discrete animation when animating between "full-width" and "proportional-width" with keyframe easing
PASS font-variation-settings (type: fontVariationSettings) has testInterpolation function
PASS font-variation-settings supports animation as float
PASS font-variation-settings supports animation as float with multiple tags
Modified: trunk/Source/WebCore/ChangeLog (291108 => 291109)
--- trunk/Source/WebCore/ChangeLog 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/Source/WebCore/ChangeLog 2022-03-10 15:57:15 UTC (rev 291109)
@@ -1,3 +1,13 @@
+2022-03-10 Antoine Quint <[email protected]>
+
+ [web-animations] font-variant-east-asian should support discrete animation
+ https://bugs.webkit.org/show_bug.cgi?id=237665
+
+ Reviewed by Myles C. Maxfield.
+
+ * animation/CSSPropertyAnimation.cpp:
+ (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):
+
2022-03-10 Rob Buis <[email protected]>
Use PropertyRegistry consistently in svgAttributeChanged
Modified: trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp (291108 => 291109)
--- trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp 2022-03-10 15:52:28 UTC (rev 291108)
+++ trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp 2022-03-10 15:57:15 UTC (rev 291109)
@@ -2592,6 +2592,47 @@
}
};
+class FontVariantEastAsianWrapper final : public AnimationPropertyWrapperBase {
+ WTF_MAKE_FAST_ALLOCATED;
+public:
+ FontVariantEastAsianWrapper()
+ : AnimationPropertyWrapperBase(CSSPropertyFontVariantEastAsian)
+ {
+ }
+
+private:
+ bool canInterpolate(const RenderStyle&, const RenderStyle&, CompositeOperation) const override { return false; }
+
+ bool equals(const RenderStyle& a, const RenderStyle& b) const override
+ {
+ auto& aFontDescription = a.fontDescription();
+ auto& bFontDescription = b.fontDescription();
+ return aFontDescription.variantEastAsianVariant() == bFontDescription.variantEastAsianVariant()
+ && aFontDescription.variantEastAsianWidth() == bFontDescription.variantEastAsianWidth()
+ && aFontDescription.variantEastAsianRuby() == bFontDescription.variantEastAsianRuby();
+ }
+
+ void blend(RenderStyle& destination, const RenderStyle& from, const RenderStyle& to, const CSSPropertyBlendingContext& context) const override
+ {
+ ASSERT(!context.progress || context.progress == 1.0);
+ auto& sourceFontDescription = (context.progress ? to : from).fontDescription();
+
+ FontSelector* currentFontSelector = destination.fontCascade().fontSelector();
+ auto description = destination.fontDescription();
+ description.setVariantEastAsianVariant(sourceFontDescription.variantEastAsianVariant());
+ description.setVariantEastAsianWidth(sourceFontDescription.variantEastAsianWidth());
+ description.setVariantEastAsianRuby(sourceFontDescription.variantEastAsianRuby());
+ destination.setFontDescription(WTFMove(description));
+ destination.fontCascade().update(currentFontSelector);
+ }
+
+#if !LOG_DISABLED
+ void logBlend(const RenderStyle&, const RenderStyle&, const RenderStyle&, double) const override
+ {
+ }
+#endif
+};
+
class CSSPropertyAnimationWrapperMap final {
WTF_MAKE_FAST_ALLOCATED;
public:
@@ -2928,7 +2969,8 @@
new CounterWrapper(CSSPropertyCounterReset),
new DiscretePropertyWrapper<WindRule>(CSSPropertyFillRule, &RenderStyle::fillRule, &RenderStyle::setFillRule),
new DiscretePropertyWrapper<FontSynthesis>(CSSPropertyFontSynthesis, &RenderStyle::fontSynthesis, &RenderStyle::setFontSynthesis),
- new DiscretePropertyWrapper<FontVariantAlternates>(CSSPropertyFontVariantAlternates, &RenderStyle::fontVariantAlternates, &RenderStyle::setFontVariantAlternates)
+ new DiscretePropertyWrapper<FontVariantAlternates>(CSSPropertyFontVariantAlternates, &RenderStyle::fontVariantAlternates, &RenderStyle::setFontVariantAlternates),
+ new FontVariantEastAsianWrapper
};
const unsigned animatableLonghandPropertiesCount = WTF_ARRAY_LENGTH(animatableLonghandPropertyWrappers);