Changeset 291147 in webkit
- Timestamp:
- Mar 10, 2022 11:26:25 PM (4 months ago)
- Location:
- trunk
- Files:
-
- 7 edited
-
LayoutTests/imported/w3c/ChangeLog (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/animation/CSSPropertyAnimation.cpp (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/imported/w3c/ChangeLog
r291130 r291147 1 2022-03-10 Antoine Quint <graouts@webkit.org> 2 3 [web-animations] font-variant-numeric should support discrete animation 4 https://bugs.webkit.org/show_bug.cgi?id=237669 5 6 Reviewed by Antti Koivisto. 7 8 * web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt: 9 * web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt: 10 * web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt: 11 * web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt: 12 1 13 2022-03-10 Antoine Quint <graouts@webkit.org> 2 14 -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/parsing/marker-supported-properties-in-animation-expected.txt
r291119 r291147 12 12 FAIL Animation of font-synthesis-style in ::marker assert_true: font-synthesis-style doesn't seem to be supported in the computed style expected true got false 13 13 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 14 FAIL Animation of font-variant in ::marker assert_equals: expected "small-caps" but got "small-caps tabular-nums" 14 PASS Animation of font-variant in ::marker 15 15 PASS Animation of font-variant-caps in ::marker 16 16 PASS Animation of font-variant-east-asian in ::marker 17 17 PASS Animation of font-variant-ligatures in ::marker 18 FAIL Animation of font-variant-numeric in ::marker assert_equals: expected "slashed-zero" but got "tabular-nums" 18 PASS Animation of font-variant-numeric in ::marker 19 19 PASS Animation of font-variant-position in ::marker 20 20 PASS Animation of font-weight in ::marker -
trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/accumulation-per-property-001-expected.txt
r291122 r291147 267 267 PASS font-variant-ligatures: "no-common-ligatures" onto "common-ligatures" 268 268 PASS font-variant-ligatures: "common-ligatures" onto "no-common-ligatures" 269 PASS font-variant-numeric (type: discrete) has testAccumulation function 270 PASS font-variant-numeric: "oldstyle-nums" onto "lining-nums" 271 PASS font-variant-numeric: "lining-nums" onto "oldstyle-nums" 269 272 PASS font-variant-position (type: discrete) has testAccumulation function 270 273 PASS font-variant-position: "super" onto "sub" -
trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/addition-per-property-001-expected.txt
r291122 r291147 267 267 PASS font-variant-ligatures: "no-common-ligatures" onto "common-ligatures" 268 268 PASS font-variant-ligatures: "common-ligatures" onto "no-common-ligatures" 269 PASS font-variant-numeric (type: discrete) has testAddition function 270 PASS font-variant-numeric: "oldstyle-nums" onto "lining-nums" 271 PASS font-variant-numeric: "lining-nums" onto "oldstyle-nums" 269 272 PASS font-variant-position (type: discrete) has testAddition function 270 273 PASS font-variant-position: "super" onto "sub" -
trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-001-expected.txt
r291122 r291147 326 326 PASS font-variant-ligatures uses discrete animation when animating between "common-ligatures" and "no-common-ligatures" with effect easing 327 327 PASS font-variant-ligatures uses discrete animation when animating between "common-ligatures" and "no-common-ligatures" with keyframe easing 328 PASS font-variant-numeric (type: discrete) has testInterpolation function 329 PASS font-variant-numeric uses discrete animation when animating between "lining-nums" and "oldstyle-nums" with linear easing 330 PASS font-variant-numeric uses discrete animation when animating between "lining-nums" and "oldstyle-nums" with effect easing 331 PASS font-variant-numeric uses discrete animation when animating between "lining-nums" and "oldstyle-nums" with keyframe easing 328 332 PASS font-variant-position (type: discrete) has testInterpolation function 329 333 PASS font-variant-position uses discrete animation when animating between "sub" and "super" with linear easing -
trunk/Source/WebCore/ChangeLog
r291144 r291147 1 2022-03-10 Antoine Quint <graouts@webkit.org> 2 3 [web-animations] font-variant-numeric should support discrete animation 4 https://bugs.webkit.org/show_bug.cgi?id=237669 5 6 Reviewed by Antti Koivisto. 7 8 We can also add support for animating the font-variant shorthand since 9 font-variant-numeric is the last of its longhands that was lacking 10 animation support. 11 12 * animation/CSSPropertyAnimation.cpp: 13 (WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap): 14 1 15 2022-03-10 Peng Liu <peng.liu6@apple.com> 2 16 -
trunk/Source/WebCore/animation/CSSPropertyAnimation.cpp
r291130 r291147 2754 2754 destination.setNamedGridAreaColumnCount(source.namedGridAreaColumnCount()); 2755 2755 } 2756 }; 2757 2758 class FontVariantNumericWrapper final : public AnimationPropertyWrapperBase { 2759 WTF_MAKE_FAST_ALLOCATED; 2760 public: 2761 FontVariantNumericWrapper() 2762 : AnimationPropertyWrapperBase(CSSPropertyFontVariantNumeric) 2763 { 2764 } 2765 2766 private: 2767 bool canInterpolate(const RenderStyle&, const RenderStyle&, CompositeOperation) const override { return false; } 2768 2769 bool equals(const RenderStyle& a, const RenderStyle& b) const override 2770 { 2771 auto& aFontDescription = a.fontDescription(); 2772 auto& bFontDescription = b.fontDescription(); 2773 return aFontDescription.variantNumericFigure() == bFontDescription.variantNumericFigure() 2774 && aFontDescription.variantNumericSpacing() == bFontDescription.variantNumericSpacing() 2775 && aFontDescription.variantNumericFraction() == bFontDescription.variantNumericFraction() 2776 && aFontDescription.variantNumericOrdinal() == bFontDescription.variantNumericOrdinal() 2777 && aFontDescription.variantNumericSlashedZero() == bFontDescription.variantNumericSlashedZero(); 2778 } 2779 2780 void blend(RenderStyle& destination, const RenderStyle& from, const RenderStyle& to, const CSSPropertyBlendingContext& context) const override 2781 { 2782 ASSERT(!context.progress || context.progress == 1.0); 2783 auto& sourceFontDescription = (context.progress ? to : from).fontDescription(); 2784 2785 FontSelector* currentFontSelector = destination.fontCascade().fontSelector(); 2786 auto description = destination.fontDescription(); 2787 description.setVariantNumericFigure(sourceFontDescription.variantNumericFigure()); 2788 description.setVariantNumericSpacing(sourceFontDescription.variantNumericSpacing()); 2789 description.setVariantNumericFraction(sourceFontDescription.variantNumericFraction()); 2790 description.setVariantNumericOrdinal(sourceFontDescription.variantNumericOrdinal()); 2791 description.setVariantNumericSlashedZero(sourceFontDescription.variantNumericSlashedZero()); 2792 destination.setFontDescription(WTFMove(description)); 2793 destination.fontCascade().update(currentFontSelector); 2794 } 2795 2796 #if !LOG_DISABLED 2797 void logBlend(const RenderStyle&, const RenderStyle&, const RenderStyle&, double) const override 2798 { 2799 } 2800 #endif 2756 2801 }; 2757 2802 … … 3125 3170 new FontVariantEastAsianWrapper, 3126 3171 new FontVariantLigaturesWrapper, 3172 new FontVariantNumericWrapper, 3127 3173 new DiscretePropertyWrapper<FontVariantPosition>(CSSPropertyFontVariantPosition, &RenderStyle::fontVariantPosition, &RenderStyle::setFontVariantPosition), 3128 3174 new DiscretePropertyWrapper<FontVariantCaps>(CSSPropertyFontVariantCaps, &RenderStyle::fontVariantCaps, &RenderStyle::setFontVariantCaps), … … 3162 3208 CSSPropertyPerspectiveOrigin, 3163 3209 CSSPropertyOffset, 3164 CSSPropertyTextEmphasis 3210 CSSPropertyTextEmphasis, 3211 CSSPropertyFontVariant 3165 3212 }; 3166 3213 const unsigned animatableShorthandPropertiesCount = WTF_ARRAY_LENGTH(animatableShorthandProperties);
Note: See TracChangeset
for help on using the changeset viewer.