[webkit-changes] [WebKit/WebKit] fbfd1d: Disable `text-wrap: balance` when not supported

Commit Queue noreply at github.com
Thu Aug 17 19:05:21 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: fbfd1da0436076fe0703cf2d2ccd9a428080700d
      https://github.com/WebKit/WebKit/commit/fbfd1da0436076fe0703cf2d2ccd9a428080700d
  Author: David Choi <david_choi5 at apple.com>
  Date:   2023-08-17 (Thu, 17 Aug 2023)

  Changed paths:
    M Source/WebCore/layout/formattingContexts/inline/InlineContentBalancer.cpp

  Log Message:
  -----------
  Disable `text-wrap: balance` when not supported
https://bugs.webkit.org/show_bug.cgi?id=260351
rdar://114031168

Reviewed by Alan Baradlay.

This patch disables `text-wrap: balance` when it encounters something
that it cannot balance. This includes:
- soft hyphens
- preserved tabs
- box-decoration-break: clone

* Source/WebCore/layout/formattingContexts/inline/InlineContentBalancer.cpp:
(WebCore::Layout::containsTrailingSoftHyphen):
(WebCore::Layout::containsPreservedTab):
(WebCore::Layout::cannotBalanceInlineItem):
(WebCore::Layout::InlineContentBalancer::initialize):

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




More information about the webkit-changes mailing list