[webkit-changes] [WebKit/WebKit] b2a00a: @font-face src format() should parse valid unsuppo...

Vitor Roriz noreply at github.com
Thu Jul 13 11:08:49 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: b2a00a22e3c413618df230613ed43dfbf9d2e39f
      https://github.com/WebKit/WebKit/commit/b2a00a22e3c413618df230613ed43dfbf9d2e39f
  Author: Vitor Roriz <vitor.roriz at apple.com>
  Date:   2023-07-13 (Thu, 13 Jul 2023)

  Changed paths:
    M LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-face-src-format-expected.txt
    M Source/WebCore/css/parser/CSSPropertyParserHelpers.cpp
    M Source/WebCore/css/parser/CSSSupportsParser.cpp

  Log Message:
  -----------
  @font-face src format() should parse valid unsupported keywords
https://bugs.webkit.org/show_bug.cgi?id=259144
rdar://112135869

Reviewed by Tim Nguyen.

A valid format() keyword (ident) argument should be parsed even if the represented
format is not supported by the engine. The engine should reject loading
the font for unsupported formats but this should happen only at
loading time and not at parsing time.

The reason why we were rejecting it before, at parsing time, is for some
inconsistency in different parts of the spec. That
will be fixed soon by the CSSWG, see: https://github.com/w3c/csswg-drafts/issues/8793

* LayoutTests/imported/w3c/web-platform-tests/css/css-fonts/parsing/font-face-src-format-expected.txt:
* Source/WebCore/css/parser/CSSPropertyParserHelpers.cpp:
(WebCore::CSSPropertyParserHelpers::isFontFormatKeywordValid):
(WebCore::CSSPropertyParserHelpers::consumeFontFormat):
* Source/WebCore/css/parser/CSSSupportsParser.cpp:
(WebCore::CSSSupportsParser::consumeSupportsFontFormatFunction):

Canonical link: https://commits.webkit.org/266043@main




More information about the webkit-changes mailing list