Bug 249840

Summary: [text-wrap] Support text-wrap: balance
Product: WebKit Reporter: Tim Nguyen (:ntim) <ntim>
Component: Layout and RenderingAssignee: David Choi <david_choi5>
Status: RESOLVED FIXED    
Severity: Normal CC: andrew, bfulgham, bramus, bugs.webkit.org, dev, hellodanielgamage, johannes.odland, rik, safari-dev, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 245561    

Tim Nguyen (:ntim)
Reported 2022-12-23 00:15:10 PST
https://drafts.csswg.org/css-text-4/#valdef-text-wrap-balance > balance Same as wrap for inline boxes. For block containers that establish an inline formatting context, line breaks are chosen to balance the remaining (empty) space in each line box, if better balance than wrap is possible. This must not change the number of line boxes the block would contain if text-wrap were set to wrap. The remaining space to consider is that which remains after placing floats and inline content, but before any adjustments due to text justification. Line boxes are balanced when the standard deviation from the average inline-size of the remaining space in each line box is reduced over the block (including lines that end in a forced break). The exact algorithm is UA-defined. UAs may treat this value as wrap if there are more than ten lines to balance.
Attachments
Radar WebKit Bug Importer
Comment 1 2022-12-23 00:16:46 PST
Tim Nguyen (:ntim)
Comment 2 2022-12-23 01:32:47 PST
*** Bug 230473 has been marked as a duplicate of this bug. ***
David Choi
Comment 3 2023-06-27 15:44:39 PDT
David Choi
Comment 4 2023-08-07 15:39:56 PDT
David Choi
Comment 5 2023-08-15 15:20:39 PDT
EWS
Comment 6 2023-08-16 19:53:13 PDT
Committed 266980@main (2d299a2dd8bb): <https://commits.webkit.org/266980@main> Reviewed commits have been landed. Closing PR #16723 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.