markDirty();
return normalFlowLayoutBuilder.endSection(getPageBox(), sectionBox);
}
case Renderer.TYPE_FOOTER:
{
final BlockRenderBox footerArea = pageBox.getFooterArea();
if (sectionBox.getFirstChild() == sectionBox.getLastChild() &&
isEmptyOrMarker(footerArea.getFirstChild()) &&
isEmptyOrMarker(sectionBox.getFirstChild()))
{
// both boxes are empty, so we can ignore it ...
return footerLayoutBuilder.endSection(footerArea, sectionBox);
}
markDirty();
return footerLayoutBuilder.endSection(footerArea, sectionBox);
}
case Renderer.TYPE_HEADER:
{
final BlockRenderBox headerArea = pageBox.getHeaderArea();
if (sectionBox.getFirstChild() == sectionBox.getLastChild() &&
isEmptyOrMarker(headerArea.getFirstChild()) &&
isEmptyOrMarker(sectionBox.getFirstChild()))
{
// both boxes are empty, so we can ignore it ...
return headerLayoutBuilder.endSection(headerArea, sectionBox);
}