Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support first-line related CSS interactions in
text-wrap: balance
https://bugs.webkit.org/show_bug.cgi?id=260229 rdar://113934501 Reviewed by Alan Baradlay. This patch implements support for first-line styling, text-indent, and white-space-collapse in text-wrap: balance. All three of these properties depend on special-casing the first line when balancing inline content. In the case of white-space-collapse: preserve, we mostly trim leading/trailing white space, except in the case where there is preserved leading white space on the first line. This patch also supports white-space-collapse: break-spaces. * LayoutTests/TestExpectations: * Source/WebCore/layout/formattingContexts/inline/InlineContentBalancer.cpp: (WebCore::Layout::InlineContentBalancer::initialize): (WebCore::Layout::InlineContentBalancer::computeBalanceConstraints): (WebCore::Layout::InlineContentBalancer::balanceRangeWithLineRequirement): (WebCore::Layout::InlineContentBalancer::balanceRangeWithNoLineRequirement): (WebCore::Layout::InlineContentBalancer::inlineItemWidth const): (WebCore::Layout::InlineContentBalancer::shouldTrimLeading const): (WebCore::Layout::InlineContentBalancer::shouldTrimTrailing const): (WebCore::Layout::InlineContentBalancer::SlidingWidth::SlidingWidth): (WebCore::Layout::InlineContentBalancer::SlidingWidth::advanceStart): (WebCore::Layout::InlineContentBalancer::SlidingWidth::advanceEnd): * Source/WebCore/layout/formattingContexts/inline/InlineContentBalancer.h: Canonical link: https://commits.webkit.org/267009@main
- Loading branch information