aboutsummaryrefslogtreecommitdiffstats
path: root/fop-core/src/main
diff options
context:
space:
mode:
authorSimon Steiner <ssteiner@apache.org>2020-12-15 13:47:13 +0000
committerSimon Steiner <ssteiner@apache.org>2020-12-15 13:47:13 +0000
commit655ac8ba9dd5fe781c2358051694311bbf21092a (patch)
treed0c21f74f735ae250c5fd1f243c6815919bc17cb /fop-core/src/main
parent6286d8b7453f7ed3238acad74d4beb1d21db449c (diff)
downloadxmlgraphics-fop-655ac8ba9dd5fe781c2358051694311bbf21092a.tar.gz
xmlgraphics-fop-655ac8ba9dd5fe781c2358051694311bbf21092a.zip
FOP-2990: Changing ipd doesn't handle table narrowing
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@1884463 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'fop-core/src/main')
-rw-r--r--fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java b/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java
index 333419649..453f169e1 100644
--- a/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java
+++ b/fop-core/src/main/java/org/apache/fop/layoutmgr/table/TableLayoutManager.java
@@ -79,6 +79,7 @@ public class TableLayoutManager extends SpacedBorderedPaddedBlockLayoutManager
private Block curBlockArea;
private double tableUnit;
+ private double oldTableUnit;
private boolean autoLayout = true;
private int halfBorderSeparationBPD;
@@ -241,7 +242,8 @@ public class TableLayoutManager extends SpacedBorderedPaddedBlockLayoutManager
* for proportional-column-width()
*/
if (tableUnit == 0.0) {
- this.tableUnit = columns.computeTableUnit(this);
+ tableUnit = columns.computeTableUnit(this);
+ tableUnit = Math.max(tableUnit, oldTableUnit);
}
if (!firstVisibleMarkServed) {
@@ -531,6 +533,7 @@ public class TableLayoutManager extends SpacedBorderedPaddedBlockLayoutManager
public void reset() {
super.reset();
curBlockArea = null;
+ oldTableUnit = tableUnit;
tableUnit = 0.0;
}