You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by gm...@apache.org on 2004/11/10 12:01:03 UTC
cvs commit: xml-fop/src/java/org/apache/fop/layoutmgr PageSequenceLayoutManager.java
gmazza 2004/11/10 03:01:03
Modified: src/java/org/apache/fop/layoutmgr
PageSequenceLayoutManager.java
Log:
Minor simplification to layoutStaticContent() method.
Revision Changes Path
1.11 +9 -12 xml-fop/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java
Index: PageSequenceLayoutManager.java
===================================================================
RCS file: /home/cvs/xml-fop/src/java/org/apache/fop/layoutmgr/PageSequenceLayoutManager.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -r1.10 -r1.11
--- PageSequenceLayoutManager.java 24 Oct 2004 00:03:50 -0000 1.10
+++ PageSequenceLayoutManager.java 10 Nov 2004 11:01:03 -0000 1.11
@@ -484,7 +484,7 @@
return curPage;
}
- private void layoutStaticContent(Region region, int regionClass) {
+ private void layoutStaticContent(Region region) {
if (region == null) {
return;
}
@@ -492,7 +492,8 @@
if (flow == null) {
return;
}
- RegionViewport reg = curPage.getPage().getRegionViewport(regionClass);
+
+ RegionViewport reg = curPage.getPage().getRegionViewport(region.getNameId());
if (reg == null) {
log.error("no region viewport: shouldn't happen");
}
@@ -511,7 +512,7 @@
lm.addAreas(new BreakPossPosIter(vecBreakPoss, 0,
vecBreakPoss.size()), null);
} else {
- log.error("bp==null cls=" + regionClass);
+ log.error("bp==null cls=" + region.getRegionName());
}
}
//lm.flush();
@@ -524,14 +525,10 @@
}
// Layout static content into the regions
// Need help from pageseq for this
- layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_BEFORE),
- FO_REGION_BEFORE);
- layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_AFTER),
- FO_REGION_AFTER);
- layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_START),
- FO_REGION_START);
- layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_END),
- FO_REGION_END);
+ layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_BEFORE));
+ layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_AFTER));
+ layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_START));
+ layoutStaticContent(currentSimplePageMaster.getRegion(FO_REGION_END));
// Queue for ID resolution and rendering
areaTreeModel.addPage(curPage);
curPage = null;
---------------------------------------------------------------------
To unsubscribe, e-mail: fop-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-cvs-help@xml.apache.org