Bug 217427

Summary: [LFC][Integration] Add line iterator
Product: WebKit Reporter: Antti Koivisto <koivisto>
Component: Layout and RenderingAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: annulen, bfulgham, cdumez, esprehn+autocc, ews-watchlist, gyuyoung.kim, kangil.han, ryuan.choi, sergio, simon.fraser, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
patch none

Description Antti Koivisto 2020-10-07 05:24:32 PDT
Iterate lines
Comment 1 Antti Koivisto 2020-10-07 06:38:48 PDT
Created attachment 410747 [details]
patch
Comment 2 zalan 2020-10-07 08:22:49 PDT
Comment on attachment 410747 [details]
patch

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

> Source/WebCore/layout/integration/LayoutIntegrationRunIterator.h:65
> +    float logicalLeft() const { return isHorizontal() ? rect().x() : rect().y(); }
> +    float logicalRight() const { return isHorizontal() ? rect().maxX() : rect().maxY(); }
> +    float logicalWidth() const { return isHorizontal() ? rect().width() : rect().height(); }
> +    float logicalHeight() const { return isHorizontal() ? rect().height() : rect().width(); }

Assuming that the display items are all flipped from logical to physical during the layout -> display transition, is this the case when the caller really expects logical coordinates here and we need to flip them back from physical to logical (curious about the use case)?
Comment 3 EWS 2020-10-07 08:47:21 PDT
Committed r268124: <https://trac.webkit.org/changeset/268124>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 410747 [details].
Comment 4 Radar WebKit Bug Importer 2020-10-07 08:48:17 PDT
<rdar://problem/70049577>
Comment 5 Antti Koivisto 2020-10-07 08:51:09 PDT
> Assuming that the display items are all flipped from logical to physical
> during the layout -> display transition, is this the case when the caller
> really expects logical coordinates here and we need to flip them back from
> physical to logical (curious about the use case)?

These are here just to make porting the existing InlineBox based code easier. It sometimes uses logical coordinates. It should be pretty easy to systematically convert such code later by eliminating these APIs.