void LayoutMultiColumnSpannerPlaceholder::layout() { ASSERT(needsLayout()); // The placeholder, like any other block level object, has its logical top // calculated and set before layout. Copy this to the actual column-span:all // object before laying it out, so that it gets paginated correctly, in case // we have an enclosing fragmentation context. m_layoutObjectInFlowThread->setLogicalTop(logicalTop()); // Lay out the actual column-span:all element. m_layoutObjectInFlowThread->layoutIfNeeded(); // The spanner has now been laid out, so its height is known. Time to update // the placeholder's height as well, so that we take up the correct amount of // space in the multicol container. updateLogicalHeight(); // Take the overflow from the spanner, so that it gets propagated to the // multicol container and beyond. m_overflow.reset(); addContentsVisualOverflow(m_layoutObjectInFlowThread->visualOverflowRect()); addLayoutOverflow(m_layoutObjectInFlowThread->layoutOverflowRect()); clearNeedsLayout(); }
void LayoutMultiColumnSet::addOverflowFromChildren() { LayoutRect overflowRect; for (const auto& group : m_fragmentainerGroups) { LayoutRect rect = group.calculateOverflow(); rect.move(group.offsetFromColumnSet()); overflowRect.unite(rect); } addLayoutOverflow(overflowRect); addContentsVisualOverflow(overflowRect); }