WebKit Bugzilla
Attachment 359160 Details for
Bug 193448
: [LFC][Out-of-flow] Ignore bottom when the vertical values are over-constrained
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
Patch.txt (text/plain), 6.04 KB, created by
zalan
on 2019-01-15 08:17:21 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
zalan
Created:
2019-01-15 08:17:21 PST
Size:
6.04 KB
patch
obsolete
>diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog >index 2afe2bc8fbc..f37ba0f2bff 100644 >--- a/LayoutTests/ChangeLog >+++ b/LayoutTests/ChangeLog >@@ -1,3 +1,13 @@ >+2019-01-15 Zalan Bujtas <zalan@apple.com> >+ >+ [LFC][Out-of-flow] Ignore bottom when the vertical values are over-constrained >+ https://bugs.webkit.org/show_bug.cgi?id=193448 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow-expected.txt: Added. >+ * fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow.html: Added. >+ > 2019-01-14 Zalan Bujtas <zalan@apple.com> > > [LFC] Use the containing block's padding box to position out-of-flow elements. >diff --git a/LayoutTests/fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow-expected.txt b/LayoutTests/fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow-expected.txt >new file mode 100644 >index 00000000000..576468a50af >--- /dev/null >+++ b/LayoutTests/fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow-expected.txt >@@ -0,0 +1,13 @@ >+layer at (0,0) size 800x600 >+ RenderView at (0,0) size 800x600 >+layer at (0,0) size 800x600 >+ RenderBlock {HTML} at (0,0) size 800x600 >+ RenderBody {BODY} at (8,8) size 784x584 >+layer at (8,8) size 110x110 >+ RenderBlock (relative positioned) {DIV} at (0,0) size 110x110 [border: (5px solid #008000)] >+layer at (13,23) size 50x50 >+ RenderBlock (positioned) {DIV} at (5,15) size 50x50 [bgcolor=#0000FF] >+layer at (8,118) size 110x110 >+ RenderBlock (relative positioned) {DIV} at (0,110) size 110x110 [border: (5px solid #008000)] >+layer at (23,123) size 50x50 >+ RenderBlock (positioned) {DIV} at (15,5) size 50x50 [bgcolor=#0000FF] >diff --git a/LayoutTests/fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow.html b/LayoutTests/fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow.html >new file mode 100644 >index 00000000000..cc17d2e629c >--- /dev/null >+++ b/LayoutTests/fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow.html >@@ -0,0 +1,18 @@ >+<style> >+.container { >+ border: 5px solid green; >+ height: 100px; >+ width: 100px; >+ position: relative; >+} >+ >+div div { >+ background: blue; >+ position: absolute; >+ >+ height: 50px; >+ width: 50px; >+} >+</style> >+<div class=container><div style="top: 10px; bottom: 10px;"></div></div> >+<div class=container><div style="left: 10px; right: 10px"></div></div> >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 6286e838f19..aa87653072d 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,17 @@ >+2019-01-15 Zalan Bujtas <zalan@apple.com> >+ >+ [LFC][Out-of-flow] Ignore bottom when the vertical values are over-constrained >+ https://bugs.webkit.org/show_bug.cgi?id=193448 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Add missing check. We should only resolve auto values. >+ >+ Test: fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow.html >+ >+ * layout/FormattingContextGeometry.cpp: >+ (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeometry): >+ > 2019-01-14 Zalan Bujtas <zalan@apple.com> > > [LFC] Use the containing block's padding box to position out-of-flow elements. >diff --git a/Source/WebCore/layout/FormattingContextGeometry.cpp b/Source/WebCore/layout/FormattingContextGeometry.cpp >index cc38f183d60..f5fec044b2f 100644 >--- a/Source/WebCore/layout/FormattingContextGeometry.cpp >+++ b/Source/WebCore/layout/FormattingContextGeometry.cpp >@@ -301,13 +301,13 @@ VerticalGeometry FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeomet > } else if (!computedVerticalMargin.before) { > usedVerticalMargin.after = *computedVerticalMargin.after; > usedVerticalMargin.before = containingBlockHeight - (*top + borderTop + paddingTop + contentHeight() + paddingBottom + borderBottom + usedVerticalMargin.after + *bottom); >- } else { >+ } else if (!computedVerticalMargin.after) { > usedVerticalMargin.before = *computedVerticalMargin.before; > usedVerticalMargin.after = containingBlockHeight - (*top + usedVerticalMargin.before + borderTop + paddingTop + contentHeight() + paddingBottom + borderBottom + *bottom); > } > // Over-constrained? > auto boxHeight = *top + usedVerticalMargin.before + borderTop + paddingTop + contentHeight() + paddingBottom + borderBottom + usedVerticalMargin.after + *bottom; >- if (boxHeight > containingBlockHeight) >+ if (boxHeight != containingBlockHeight) > bottom = containingBlockHeight - (*top + usedVerticalMargin.before + borderTop + paddingTop + contentHeight() + paddingBottom + borderBottom + usedVerticalMargin.after); > } > >diff --git a/Tools/ChangeLog b/Tools/ChangeLog >index 95548b277e8..9c4452f38b6 100644 >--- a/Tools/ChangeLog >+++ b/Tools/ChangeLog >@@ -1,3 +1,12 @@ >+2019-01-15 Zalan Bujtas <zalan@apple.com> >+ >+ [LFC][Out-of-flow] Ignore bottom when the vertical values are over-constrained >+ https://bugs.webkit.org/show_bug.cgi?id=193448 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * LayoutReloaded/misc/LFC-passing-tests.txt: >+ > 2019-01-14 Zalan Bujtas <zalan@apple.com> > > [LFC] Use the containing block's padding box to position out-of-flow elements. >diff --git a/Tools/LayoutReloaded/misc/LFC-passing-tests.txt b/Tools/LayoutReloaded/misc/LFC-passing-tests.txt >index 4ec9d7649ae..42d36df795f 100644 >--- a/Tools/LayoutReloaded/misc/LFC-passing-tests.txt >+++ b/Tools/LayoutReloaded/misc/LFC-passing-tests.txt >@@ -78,6 +78,7 @@ fast/block/block-only/relative-siblings.html > fast/block/block-only/relative-simple.html > fast/block/block-only/box-sizing-inflow-out-of-flow-simple.html > fast/block/block-only/out-of-flow-with-containing-block-border-padding.html >+fast/block/block-only/non-auto-top-bottom-left-right-widht-height-out-of-flow.html > fast/block/basic/002.html > fast/block/basic/003.html > fast/block/basic/006.html
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 193448
: 359160