Title: [233126] trunk/Source/WebCore
- Revision
- 233126
- Author
- [email protected]
- Date
- 2018-06-23 07:39:26 -0700 (Sat, 23 Jun 2018)
Log Message
[LFC] Relatively positioned renderer needs offsetting for validation
https://bugs.webkit.org/show_bug.cgi?id=186959
Reviewed by Antti Koivisto.
* layout/FormattingContextGeometry.cpp:
(WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeometry):
* layout/Verification.cpp:
(WebCore::Layout::outputMismatchingBoxInformationIfNeeded):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (233125 => 233126)
--- trunk/Source/WebCore/ChangeLog 2018-06-23 14:38:32 UTC (rev 233125)
+++ trunk/Source/WebCore/ChangeLog 2018-06-23 14:39:26 UTC (rev 233126)
@@ -1,5 +1,17 @@
2018-06-23 Zalan Bujtas <[email protected]>
+ [LFC] Relatively positioned renderer needs offsetting for validation
+ https://bugs.webkit.org/show_bug.cgi?id=186959
+
+ Reviewed by Antti Koivisto.
+
+ * layout/FormattingContextGeometry.cpp:
+ (WebCore::Layout::FormattingContext::Geometry::outOfFlowNonReplacedVerticalGeometry):
+ * layout/Verification.cpp:
+ (WebCore::Layout::outputMismatchingBoxInformationIfNeeded):
+
+2018-06-23 Zalan Bujtas <[email protected]>
+
[LFC] Miscellaneous fixes to fix simple absolute positioning.
https://bugs.webkit.org/show_bug.cgi?id=186962
Modified: trunk/Source/WebCore/layout/FormattingContextGeometry.cpp (233125 => 233126)
--- trunk/Source/WebCore/layout/FormattingContextGeometry.cpp 2018-06-23 14:38:32 UTC (rev 233125)
+++ trunk/Source/WebCore/layout/FormattingContextGeometry.cpp 2018-06-23 14:39:26 UTC (rev 233126)
@@ -188,7 +188,7 @@
ASSERT(marginBottom);
LOG_WITH_STREAM(FormattingContextLayout, stream << "[Position][Height][Margin] -> out-of-flow non-replaced -> top(" << *top << "px) bottom(" << *bottom << "px) height(" << *height << "px) margin(" << *marginTop << "px, " << *marginBottom << "px) layoutBox(" << &layoutBox << ")");
- return { *top, *bottom, { *height, { *marginTop, *marginBottom} } };
+ return { *top, *bottom, { *height, { *marginTop, *marginBottom } } };
}
FormattingContext::Geometry::HorizontalGeometry FormattingContext::Geometry::outOfFlowNonReplacedHorizontalGeometry(LayoutContext& layoutContext, const Box& layoutBox)
Modified: trunk/Source/WebCore/layout/Verification.cpp (233125 => 233126)
--- trunk/Source/WebCore/layout/Verification.cpp 2018-06-23 14:38:32 UTC (rev 233125)
+++ trunk/Source/WebCore/layout/Verification.cpp 2018-06-23 14:39:26 UTC (rev 233126)
@@ -57,7 +57,12 @@
auto* displayBox = context.displayBoxForLayoutBox(layoutBox);
ASSERT(displayBox);
- if (renderer.frameRect() != displayBox->rect()) {
+ auto frameRect = renderer.frameRect();
+ // rendering does not offset for relative positioned boxes.
+ if (renderer.isInFlowPositioned())
+ frameRect.move(renderer.offsetForInFlowPosition());
+
+ if (frameRect != displayBox->rect()) {
outputRect("frameBox", renderer.frameRect(), displayBox->rect());
return true;
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes