Bug 256927
Summary: | [css-text-4] Implement `white-space-collapse` & `text-wrap` as longhands of `white-space` | ||
---|---|---|---|
Product: | WebKit | Reporter: | David Choi <david_choi5> |
Component: | Layout and Rendering | Assignee: | David Choi <david_choi5> |
Status: | RESOLVED FIXED | ||
Severity: | Normal | CC: | bfulgham, ntim, simon.fraser, webkit-bug-importer, zalan |
Priority: | P2 | Keywords: | InRadar |
Version: | WebKit Nightly Build | ||
Hardware: | Unspecified | ||
OS: | Unspecified |
David Choi
Replace the existing references to RenderStyle.whiteSpace() with references to the new longhand values (white-space-collapse and text-wrap).
https://drafts.csswg.org/css-text-4/#white-space-property
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Radar WebKit Bug Importer
<rdar://problem/109486221>
alan
(In reply to David Choi from comment #0)
> Replace the existing references to RenderStyle.whiteSpace() with references
> to the new longhand values (white-space-collapse and text-wrap).
will that include white-space-trim too?
Tim Nguyen (:ntim)
(In reply to zalan from comment #2)
> (In reply to David Choi from comment #0)
> > Replace the existing references to RenderStyle.whiteSpace() with references
> > to the new longhand values (white-space-collapse and text-wrap).
> will that include white-space-trim too?
For the scope of this bug, I think we should exclude `white-space-trim` as all current `white-space` values map to `none`. Implementing the other values would be new functionality.
David Choi
For now, existing references to RenderStyle.whiteSpace() will remain as is, but the RenderStyle object itself will not hold a white-space member variable. Instead, it will hold white-space-collapse and text-wrap member variables that can reconstruct the proper value for white-space. These member variables will be set accordingly based on the parsed white-space shorthand keyword.
References to RenderStyle.setWhiteSpace() will be replaced with the appropriate references to RenderStyle.setWhiteSpaceCollapse() and RenderStyle.setTextWrap().
David Choi
Pull request: https://github.com/WebKit/WebKit/pull/14564
EWS
Committed 265267@main (eff0d22edb04): <https://commits.webkit.org/265267@main>
Reviewed commits have been landed. Closing PR #14564 and removing active labels.