Ignore:
Timestamp:
May 31, 2022, 6:24:31 AM (3 years ago)
Author:
[email protected]
Message:

Unprefix -webkit-text-justify and add inter-character value
https://bugs.webkit.org/show_bug.cgi?id=229084
<rdar://82177456>

Reviewed by Antti Koivisto.

This is still disabled by default behind the cssTextJustifyEnabled setting.
We don't keep support for the -webkit- prefix, since only Firefox ships text-justify (without the prefix) and it was never enabled in WebKit for macOS/iOS.

distribute and inter-character are aliases, with distribute being the legacy one. The spec specifies it as parse-time, but we implement it compute-time (like Chrome).

https://github.com/w3c/csswg-drafts/issues/7322 is filed about potentially removing 'distribute' from the spec.

  • LayoutTests/fast/css3-text/css3-text-justify/getComputedStyle/getComputedStyle-text-justify-expected.txt: Removed.
  • LayoutTests/fast/css3-text/css3-text-justify/getComputedStyle/getComputedStyle-text-justify-inherited-expected.txt: Removed.
  • LayoutTests/fast/css3-text/css3-text-justify/getComputedStyle/getComputedStyle-text-justify-inherited.html: Removed.
  • LayoutTests/fast/css3-text/css3-text-justify/getComputedStyle/getComputedStyle-text-justify.html: Removed.

Removed parsing tests redundant with WPT.

  • LayoutTests/fast/css3-text/css3-text-justify/text-justify-none.html:
  • LayoutTests/fast/text/text-combine-crash.html:
  • LayoutTests/TestExpectations:
  • LayoutTests/imported/w3c/resources/resource-files.json:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/first-letter-allowed-properties-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-pseudo/first-line-allowed-properties-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/inheritance-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/parsing/text-justify-computed-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/parsing/text-justify-valid-expected.txt:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/letter-spacing/letter-spacing-bidi-003.xht:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-001.html:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-002.html:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-003.html:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-004.html:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-005.html:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-006.html:
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/distribute-alias.tentative-expected.txt: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/distribute-alias.tentative.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-001-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-001.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-002-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-002.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-003-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-003.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-004-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-004.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-005-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-005.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-006-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-and-trailing-spaces-006.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-distribute-001-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-distribute-001.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-inter-character-001-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-inter-character-001-ref.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-inter-character-001.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-inter-word-001-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-inter-word-001-ref.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-inter-word-001.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-interpolation-expected.txt: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-interpolation.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-none-001-expected.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-none-001-ref.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/text-justify-none-001.html: Added.
  • LayoutTests/imported/w3c/web-platform-tests/css/css-text/text-justify/w3c-import.log:
  • LayoutTests/platform/gtk/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:
  • LayoutTests/platform/mac-wk1/imported/w3c/web-platform-tests/css/css-cascade/all-prop-revert-layer-expected.txt:
  • LayoutTests/platform/wpe/imported/w3c/web-platform-tests/css/css-cascade/all-prop-initial-xml-expected.txt:

Import new WPT from 6aa9a39, remove prefixes automatically added by the importer, and rebaseline tests.

  • Source/WebCore/animation/CSSPropertyAnimation.cpp:

(WebCore::CSSPropertyAnimationWrapperMap::CSSPropertyAnimationWrapperMap):

  • Source/WebCore/css/CSSComputedStyleDeclaration.cpp:

(WebCore::ComputedStyleExtractor::valueForPropertyInStyle):

  • Source/WebCore/css/CSSPrimitiveValueMappings.h:

(WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
(WebCore::CSSPrimitiveValue::operator TextJustify const):

  • Source/WebCore/css/CSSProperties.json:
  • Source/WebCore/css/StyleProperties.cpp:
  • Source/WebCore/css/parser/CSSParserContext.cpp:

(WebCore::CSSParserContext::isPropertyRuntimeDisabled const):

  • Source/WebCore/css/parser/CSSParserFastPaths.cpp:

(WebCore::CSSParserFastPaths::isValidKeywordPropertyAndValue):
(WebCore::CSSParserFastPaths::isKeywordPropertyID):

  • Source/WebCore/rendering/LegacyLineLayout.cpp:

(WebCore::LegacyLineLayout::textAlignmentForLine const):

  • Source/WebCore/rendering/style/RenderStyleConstants.h:
  • Source/WebInspectorUI/UserInterface/Models/CSSKeywordCompletions.js:

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

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp

    r295021 r295049  
    35623562        case CSSPropertyTextDecoration:
    35633563            return renderTextDecorationLineFlagsToCSSValue(style.textDecorationLine());
    3564         case CSSPropertyWebkitTextJustify:
     3564        case CSSPropertyTextJustify:
    35653565            if (!m_element->document().settings().cssTextJustifyEnabled())
    35663566                return nullptr;
Note: See TracChangeset for help on using the changeset viewer.