summaryrefslogtreecommitdiffstats
path: root/fop-core
diff options
context:
space:
mode:
authorSimon Steiner <ssteiner@apache.org>2019-09-24 14:11:21 +0000
committerSimon Steiner <ssteiner@apache.org>2019-09-24 14:11:21 +0000
commitccd9f65340c38010da0b96c2933abee9093fa984 (patch)
tree46cc89bf8f45cd2453c0e0ec07cb49d1e2247cde /fop-core
parent7f7464bade4b0f5aff632f3207d5e6b323372972 (diff)
downloadxmlgraphics-fop-ccd9f65340c38010da0b96c2933abee9093fa984.tar.gz
xmlgraphics-fop-ccd9f65340c38010da0b96c2933abee9093fa984.zip
FOP-2883: Penalty cause table to flow into footer
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@1867463 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'fop-core')
-rw-r--r--fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableStepper.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableStepper.java b/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableStepper.java
index ff38d692e..136f9c4e3 100644
--- a/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableStepper.java
+++ b/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableStepper.java
@@ -277,7 +277,11 @@ public class TableStepper {
if (penaltyOrGlueLen < 0) {
if (keep.getPenalty() == KnuthElement.INFINITE) {
- returnList.add(new KnuthGlue(0, -penaltyOrGlueLen, 0, new Position(null), true));
+ if (boxLen > -penaltyOrGlueLen && boxLen < maxRemainingHeight) {
+ returnList.add(new KnuthGlue(boxLen, 0, 0, new Position(null), true));
+ } else {
+ returnList.add(new KnuthGlue(0, -penaltyOrGlueLen, 0, new Position(null), true));
+ }
} else {
returnList.add(new KnuthGlue(-penaltyOrGlueLen, 0, 0, new Position(null), true));
}