Bug 245947 - Enable justified text for white-space: pre-wrap
Summary: Enable justified text for white-space: pre-wrap
Status: RESOLVED WORKSFORME
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: Safari Technology Preview
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: BrowserCompat
Depends on:
Blocks:
 
Reported: 2022-10-02 10:47 PDT by Ahmad Saleem
Modified: 2022-10-04 14:51 PDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ahmad Saleem 2022-10-02 10:47:51 PDT
Hi Team,

I was looking into another Blink Commit merge and noticed following:

Commit - https://src.chromium.org/viewvc/blink?view=revision&revision=174895

Which needs to be merged here:

https://github.com/WebKit/WebKit/blob/89d57a6f366a8abe5d012e38f160f81388b46429/Source/WebCore/rendering/LegacyLineLayout.cpp#L613

and add following:

whiteSpace() == WhiteSpace::Pre

I will see whether it is easier to do or not but will try with PR. Although, I think it would be good to keep this for future.

Thanks!
Comment 1 Ahmad Saleem 2022-10-04 14:51:16 PDT
We don't need to do this change because we already have it fixed along the way and Safari 16 behavior is consistent with Chrome Canary 108.

Example test case - https://jsfiddle.net/b7j5412r/show

If I do this change, which I was trying to do it in below PR:

https://github.com/WebKit/WebKit/pull/4912

It reverts back us to old behavior and removed "justified".

I have discussed with Alan and now closing this bug but if needed and I am not right, please let me know I will be able to turn around this patch.

Marking this as "RESOLVED WORKSFORME".