aboutsummaryrefslogtreecommitdiffstats
path: root/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java
diff options
context:
space:
mode:
authorSimon Pepping <spepping@apache.org>2006-01-10 20:18:13 +0000
committerSimon Pepping <spepping@apache.org>2006-01-10 20:18:13 +0000
commit5fca3a38d09389a5aeae503806d29ecfdd520673 (patch)
tree50c8e220715528c54ecdff01870c35e991dd0302 /src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java
parent1d7764872f439f37092c68976258fbc28463e22b (diff)
downloadxmlgraphics-fop-5fca3a38d09389a5aeae503806d29ecfdd520673.tar.gz
xmlgraphics-fop-5fca3a38d09389a5aeae503806d29ecfdd520673.zip
The last page sequence should also follow its force-page-count trait.
Replace one test case with two leaner test cases, submitted by Gerhard Oettl, see bug 38087. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@367775 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java')
-rw-r--r--src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java b/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java
index a7c6c7b6a..71b319f7e 100644
--- a/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java
+++ b/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java
@@ -893,8 +893,10 @@ public class PageSequenceLayoutManager extends AbstractLayoutManager {
}
- /*
- * check if the page-number of the last page suits to the force-page-count property
+ /**
+ * Act upon the force-page-count trait,
+ * in relation to the initial-page-number trait of the following page-sequence.
+ * @param nextPageSeqInitialPageNumber initial-page-number trait of next page-sequence
*/
public void doForcePageCount(Numeric nextPageSeqInitialPageNumber) {
@@ -913,7 +915,7 @@ public class PageSequenceLayoutManager extends AbstractLayoutManager {
// if force-page-count is auto then set the value of forcePageCount
// depending on the initial-page-number of the next page-sequence
- if (forcePageCount == Constants.EN_AUTO) {
+ if (nextPageSeqInitialPageNumber != null && forcePageCount == Constants.EN_AUTO) {
if (nextPageSeqInitialPageNumber.getEnum() != 0) {
// auto | auto-odd | auto-even
int nextPageSeqPageNumberType = nextPageSeqInitialPageNumber.getEnum();