Bug 259958 - Support text-wrap: balance in legacy line layout
Summary: Support text-wrap: balance in legacy line layout
Status: RESOLVED INVALID
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: David Choi
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-08-08 17:07 PDT by David Choi
Modified: 2024-01-29 12:30 PST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Choi 2023-08-08 17:07:26 PDT
Given that IFC and LFC are radically different in their treatment of laying out inline content, there must exist a separate implementation of `text-wrap: balance` in both codepaths. IFC is easier to work with, and therefore allows more complex implementations of text-balancing than LFC. In LFC, if we decide to implement `text-wrap: balance`, then it will likely have to be a simple approach, such as a binary search approach that runs line layout in a loop.
Comment 1 Radar WebKit Bug Importer 2023-08-08 17:08:04 PDT
<rdar://problem/113595624>
Comment 2 David Choi 2023-08-08 17:16:42 PDT
Pull request: https://github.com/WebKit/WebKit/pull/16502
Comment 3 zalan 2023-08-08 17:20:52 PDT
(In reply to David Choi from comment #0)
> Given that IFC and LFC are radically different in their treatment of laying
> out inline content, there must exist a separate implementation of
> `text-wrap: balance` in both codepaths. IFC is easier to work with, and
> therefore allows more complex implementations of text-balancing than LFC. In
> LFC, if we decide to implement `text-wrap: balance`, then it will likely
> have to be a simple approach, such as a binary search approach that runs
> line layout in a loop.
Just a small correction; LFC stands for Layout Formatting Context. It is an umbrella project for WebKit's next-gen layout. IFC (Inline Formatting Context) is part of this initiative and it implements CSS inline layout.
Legacy line layout is the fallback codepath for content not supported by IFC.
Comment 4 zalan 2024-01-29 12:30:43 PST
not applicable anymore.