Bug 192214 - [LFC][BFC][MarginCollapsing] Do not use computed display box values for border and padding
Summary: [LFC][BFC][MarginCollapsing] Do not use computed display box values for borde...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: zalan
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-11-29 21:11 PST by zalan
Modified: 2018-11-30 07:23 PST (History)
5 users (show)

See Also:


Attachments
Patch (11.94 KB, patch)
2018-11-29 21:27 PST, zalan
koivisto: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description zalan 2018-11-29 21:11:32 PST
they are not computed yet when we are trying to estimate margin top values. try to survive with the non-computed values.

<body><div style="float: left"></div><div><div style="margin-top: 10px">foobar</div></div>
when the floating box is placed, we need to know its final vertical position. We estimate margin tops all the way to the formatting context root. To computer margin-top for the <body>, we actually have to know if that nested div's margin gets collapsed all the way up. To find it out we need to know padding and border values. Unfortunately at the time when the float is placed we don't yet have that information.
Comment 1 zalan 2018-11-29 21:27:43 PST
Created attachment 356127 [details]
Patch
Comment 2 zalan 2018-11-30 07:22:46 PST
Committed r238735: <https://trac.webkit.org/changeset/238735>
Comment 3 Radar WebKit Bug Importer 2018-11-30 07:23:37 PST
<rdar://problem/46372648>