Changeset 283536 in webkit
- Timestamp:
- Oct 4, 2021 8:52:13 PM (10 months ago)
- Location:
- trunk
- Files:
-
- 13 edited
-
LayoutTests/imported/w3c/ChangeLog (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-computed-expected.txt (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-computed.html (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-invalid-expected.txt (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-invalid.html (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-valid-expected.txt (modified) (1 diff)
-
LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-valid.html (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/css/CSSComputedStyleDeclaration.cpp (modified) (1 diff)
-
Source/WebCore/css/parser/CSSPropertyParser.cpp (modified) (1 diff)
-
Source/WebCore/platform/graphics/FontPalette.h (modified) (2 diffs)
-
Source/WebCore/platform/graphics/cocoa/FontCacheCoreText.cpp (modified) (1 diff)
-
Source/WebCore/style/StyleBuilderConverter.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/imported/w3c/ChangeLog
r283534 r283536 1 2021-10-04 Myles C. Maxfield <mmaxfield@apple.com> 2 3 Remove the "none" value from font-palette 4 https://bugs.webkit.org/show_bug.cgi?id=231050 5 <rdar://problem/83745650> 6 7 Reviewed by Wenson Hsieh. 8 9 This is being upstreamed at https://github.com/web-platform-tests/wpt/pull/31077. 10 11 * web-platform-tests/css/css-fonts/parsing/font-palette-invalid.html: 12 * web-platform-tests/css/css-fonts/parsing/font-palette-valid.html: 13 1 14 2021-10-04 Myles C. Maxfield <mmaxfield@apple.com> 2 15 -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-computed-expected.txt
r283221 r283536 1 1 2 PASS Property font-palette value 'none'3 2 PASS Property font-palette value 'normal' 4 3 PASS Property font-palette value 'light' -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-computed.html
r283221 r283536 13 13 <div id="target"></div> 14 14 <script> 15 test_computed_value('font-palette', 'none');16 15 test_computed_value('font-palette', 'normal'); 17 16 test_computed_value('font-palette', 'light'); -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-invalid-expected.txt
r283221 r283536 3 3 PASS e.style['font-palette'] = "none, light" should not set the property value 4 4 PASS e.style['font-palette'] = "A" should not set the property value 5 PASS e.style['font-palette'] = "none" should not set the property value 5 6 -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-invalid.html
r283221 r283536 15 15 test_invalid_value('font-palette', 'none, light'); 16 16 test_invalid_value('font-palette', 'A'); 17 test_invalid_value('font-palette', 'none'); 17 18 </script> 18 19 </body> -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-valid-expected.txt
r283221 r283536 1 1 2 PASS e.style['font-palette'] = "none" should set the property value3 2 PASS e.style['font-palette'] = "normal" should set the property value 4 3 PASS e.style['font-palette'] = "light" should set the property value -
trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-valid.html
r283221 r283536 12 12 <body> 13 13 <script> 14 test_valid_value('font-palette', 'none');15 14 test_valid_value('font-palette', 'normal'); 16 15 test_valid_value('font-palette', 'light'); -
trunk/Source/WebCore/ChangeLog
r283535 r283536 1 2021-10-04 Myles C. Maxfield <mmaxfield@apple.com> 2 3 Remove the "none" value from font-palette 4 https://bugs.webkit.org/show_bug.cgi?id=231050 5 <rdar://problem/83745650> 6 7 Reviewed by Wenson Hsieh. 8 9 The spec changed in 10 https://github.com/w3c/csswg-drafts/commit/b7103b0269cde51914af02f5ca1e5582d44e7b70. 11 Luckily, we never implemented this anyway, so this is just a parsing change. 12 13 Tests: imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-invalid.html 14 imported/w3c/web-platform-tests/css/css-fonts/parsing/font-palette-valid.html 15 16 * css/CSSComputedStyleDeclaration.cpp: 17 (WebCore::fontPaletteFromStyle): 18 * css/parser/CSSPropertyParser.cpp: 19 (WebCore::consumeFontPalette): 20 * platform/graphics/FontPalette.h: 21 (WebCore::operator<<): 22 * platform/graphics/cocoa/FontCacheCoreText.cpp: 23 (WebCore::addAttributesForFontPalettes): 24 * style/StyleBuilderConverter.h: 25 (WebCore::Style::BuilderConverter::convertFontPalette): 26 1 27 2021-10-04 Alan Bujtas <zalan@apple.com> 2 28 -
trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp
r283159 r283536 1842 1842 auto fontPalette = style.fontDescription().fontPalette(); 1843 1843 switch (fontPalette.type) { 1844 case FontPalette::Type::None:1845 return CSSValuePool::singleton().createIdentifierValue(CSSValueNone);1846 1844 case FontPalette::Type::Normal: 1847 1845 return CSSValuePool::singleton().createIdentifierValue(CSSValueNormal); -
trunk/Source/WebCore/css/parser/CSSPropertyParser.cpp
r283398 r283536 930 930 static RefPtr<CSSPrimitiveValue> consumeFontPalette(CSSParserTokenRange& range) 931 931 { 932 if (auto result = consumeIdent<CSSValueNo ne, CSSValueNormal, CSSValueLight, CSSValueDark>(range))932 if (auto result = consumeIdent<CSSValueNormal, CSSValueLight, CSSValueDark>(range)) 933 933 return result; 934 934 return consumeDashedIdent(range); -
trunk/Source/WebCore/platform/graphics/FontPalette.h
r283082 r283536 47 47 48 48 enum class Type : uint8_t { 49 None,50 49 Normal, 51 50 Light, … … 67 66 { 68 67 switch (fontPalette.type) { 69 case FontPalette::Type::None:70 ts << "none";71 break;72 68 case FontPalette::Type::Normal: 73 69 ts << "normal"; -
trunk/Source/WebCore/platform/graphics/cocoa/FontCacheCoreText.cpp
r283431 r283536 500 500 { 501 501 switch (fontPalette.type) { 502 case FontPalette::Type::None:503 // This is unimplementable in Core Text.504 break;505 502 case FontPalette::Type::Normal: 506 503 break; -
trunk/Source/WebCore/style/StyleBuilderConverter.h
r282851 r283536 1556 1556 const auto& primitiveValue = downcast<CSSPrimitiveValue>(value); 1557 1557 switch (primitiveValue.valueID()) { 1558 case CSSValueNone:1559 return { FontPalette::Type::None, nullAtom() };1560 1558 case CSSValueNormal: 1561 1559 return { FontPalette::Type::Normal, nullAtom() };
Note: See TracChangeset
for help on using the changeset viewer.