Bug 205245

Summary: [LFC][IFC] Fix imported/w3c/web-platform-tests/css/css-text/overflow-wrap/overflow-wrap-break-word-006.html
Product: WebKit Reporter: zalan <zalan>
Component: Layout and RenderingAssignee: zalan <zalan>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, koivisto, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch koivisto: review+

Description zalan 2019-12-14 21:29:44 PST
ssia
Comment 1 Radar WebKit Bug Importer 2019-12-14 21:30:15 PST
<rdar://problem/57943885>
Comment 2 zalan 2019-12-14 21:45:36 PST
Created attachment 385708 [details]
Patch
Comment 3 Antti Koivisto 2019-12-15 00:03:24 PST
Comment on attachment 385708 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=385708&action=review

> Source/WebCore/layout/inlineformatting/InlineLineBreaker.cpp:109
> +        if (auto partialTrailingContent = wrapTextContent(runs, lineStatus)) {

Here the returned variable is called "content".

> Source/WebCore/layout/inlineformatting/InlineLineBreaker.h:125
> +    struct TextWrappingContext {
> +        unsigned trailingRunIndex { 0 };
> +        bool contentOverflows { false };
> +        Optional<PartialRun> partialTrailingRun;
> +    };
> +    Optional<TextWrappingContext> wrapTextContent(const Content::RunList&, const LineStatus&) const;

Not sure I understand how this type is a "context". 

context
noun
1 the historical context out of which the novel arose: circumstances, conditions, surroundings, factors, state of affairs; situation, environment, milieu, setting, background, backdrop, scene; climate, atmosphere, ambience, mood, feel.

It is also confusing that it is returned by function called "content".

Based on your variable naming above, maybe the type should be "PartialTrailingContent"? Or based on the function naming "WrappedTextContent"? In this case you might want to rename the variables too.
Comment 4 zalan 2019-12-15 05:50:08 PST
Committed r253533: <https://trac.webkit.org/changeset/253533>
Comment 5 zalan 2019-12-15 05:51:18 PST
(In reply to zalan from comment #4)
> Committed r253533: <https://trac.webkit.org/changeset/253533>

Oh no, I didn't mean to land it without the renaming :(
Comment 6 zalan 2019-12-15 06:03:20 PST
(In reply to zalan from comment #5)
> (In reply to zalan from comment #4)
> > Committed r253533: <https://trac.webkit.org/changeset/253533>
> 
> Oh no, I didn't mean to land it without the renaming :(

Addressed in r253534.