From ea778ff1f7256c3a8fbc55796d317af1bd5cc624 Mon Sep 17 00:00:00 2001 From: Steve Coffman Date: Tue, 16 May 2000 19:53:11 +0000 Subject: [PATCH] This patch applies Jordan Naftolin's fix for extra space being added to the bottom of tables. It also fixes the border.fo so the year is "2000" rather than "20000". Heh. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@193348 13f79535-47bb-0310-9956-ffa450edef68 --- docs/examples/fo/border.fo | 2 +- src/org/apache/fop/fo/flow/TableBody.java | 5 +++++ src/org/apache/fop/fo/flow/TableRow.java | 6 +++++- 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/docs/examples/fo/border.fo b/docs/examples/fo/border.fo index 919f291b4..ac1b3415d 100644 --- a/docs/examples/fo/border.fo +++ b/docs/examples/fo/border.fo @@ -41,7 +41,7 @@ - 01/01/20000 + 01/01/2000 diff --git a/src/org/apache/fop/fo/flow/TableBody.java b/src/org/apache/fop/fo/flow/TableBody.java index 440a53b4a..494f59718 100644 --- a/src/org/apache/fop/fo/flow/TableBody.java +++ b/src/org/apache/fop/fo/flow/TableBody.java @@ -156,6 +156,11 @@ public class TableBody extends FObj { area.increaseHeight(areaContainer.getHeight()); return status; } + // if this is not the last row, add display space + if(i!=numChildren-1) + { + areaContainer.addDisplaySpace(row.getLargestCellHeight()); + } } area.addChild(areaContainer); areaContainer.end(); diff --git a/src/org/apache/fop/fo/flow/TableRow.java b/src/org/apache/fop/fo/flow/TableRow.java index 5fd80a5ad..79c37bf69 100644 --- a/src/org/apache/fop/fo/flow/TableRow.java +++ b/src/org/apache/fop/fo/flow/TableRow.java @@ -202,7 +202,7 @@ public class TableRow extends FObj { area.addChild(areaContainer); areaContainer.end(); area.setHeight(largestCellHeight); - area.addDisplaySpace(largestCellHeight); + // bug fix from Eric Schaeffer //area.increaseHeight(largestCellHeight); @@ -220,4 +220,8 @@ public class TableRow extends FObj { public int getAreaHeight() { return areaContainer.getHeight(); } + public int getLargestCellHeight() + { + return largestCellHeight; + } } -- 2.39.5