From: Karen Lease Date: Fri, 20 Apr 2001 21:00:31 +0000 (+0000) Subject: Fix body positioning; remove widow and orhpan handling for rows X-Git-Tag: PRE_CODEFORMATTING~158 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=aae6e22943d7745a6e82f7c6b9f6a23e9de5ff6c;p=xmlgraphics-fop.git Fix body positioning; remove widow and orhpan handling for rows git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@194219 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/src/org/apache/fop/fo/flow/TableBody.java b/src/org/apache/fop/fo/flow/TableBody.java index edb774fbe..408be1e56 100644 --- a/src/org/apache/fop/fo/flow/TableBody.java +++ b/src/org/apache/fop/fo/flow/TableBody.java @@ -153,7 +153,7 @@ public class TableBody extends FObj { */ this.areaContainer = new AreaContainer(propMgr.getFontState(area.getFontInfo()), - 0,area.getHeight(), + 0,area.getContentHeight(), area.getContentWidth(), // IPD area.spaceLeft(), Position.RELATIVE); @@ -220,38 +220,38 @@ public class TableBody extends FObj { } } this.marker = i; - if ((i != 0) && + if ((i != 0) && (status.getCode() == Status.AREA_FULL_NONE)) { status = new Status(Status.AREA_FULL_SOME); } - if (i < widows && numChildren >= widows) { - resetMarker(); - return new Status(Status.AREA_FULL_NONE); - } - if (numChildren <= orphans) { - resetMarker(); - return new Status(Status.AREA_FULL_NONE); - } - if (numChildren - i < orphans && numChildren >= orphans) { - for (int count = i; - count > numChildren - orphans - 1; count--) { - row = (TableRow) children.elementAt(count); - row.removeLayout(areaContainer); - i--; - } - if (i < widows && numChildren >= widows) { - resetMarker(); - return new Status(Status.AREA_FULL_NONE); - } - this.marker = i; - area.addChild(areaContainer); - //areaContainer.end(); - - area.increaseHeight(areaContainer.getHeight()); - area.setAbsoluteHeight( - areaContainer.getAbsoluteHeight()); - return new Status(Status.AREA_FULL_SOME); - } +// if (i < widows && numChildren >= widows) { +// resetMarker(); +// return new Status(Status.AREA_FULL_NONE); +// } +// if (numChildren <= orphans) { +// resetMarker(); +// return new Status(Status.AREA_FULL_NONE); +// } +// if (numChildren - i < orphans && numChildren >= orphans) { +// for (int count = i; +// count > numChildren - orphans - 1; count--) { +// row = (TableRow) children.elementAt(count); +// row.removeLayout(areaContainer); +// i--; +// } +// if (i < widows && numChildren >= widows) { +// resetMarker(); +// return new Status(Status.AREA_FULL_NONE); +// } +// this.marker = i; +// area.addChild(areaContainer); +// //areaContainer.end(); + +// area.increaseHeight(areaContainer.getHeight()); +// area.setAbsoluteHeight( +// areaContainer.getAbsoluteHeight()); +// return new Status(Status.AREA_FULL_SOME); +// } if (!((i == 0) && (areaContainer.getContentHeight() <= 0))) { area.addChild(areaContainer);