diff options
Diffstat (limited to 'src/org/apache/fop/fo')
-rw-r--r-- | src/org/apache/fop/fo/FObj.java | 5 | ||||
-rw-r--r-- | src/org/apache/fop/fo/flow/BidiOverride.java | 4 | ||||
-rw-r--r-- | src/org/apache/fop/fo/flow/ExternalGraphic.java | 5 | ||||
-rw-r--r-- | src/org/apache/fop/fo/flow/InstreamForeignObject.java | 5 | ||||
-rw-r--r-- | src/org/apache/fop/fo/flow/Leader.java | 4 |
5 files changed, 11 insertions, 12 deletions
diff --git a/src/org/apache/fop/fo/FObj.java b/src/org/apache/fop/fo/FObj.java index fc29ef8a2..e4a0f5503 100644 --- a/src/org/apache/fop/fo/FObj.java +++ b/src/org/apache/fop/fo/FObj.java @@ -211,7 +211,10 @@ public class FObj extends FONode { * @return A ListIterator. */ public ListIterator getChildren() { - return children.listIterator(); + if(children != null) { + return children.listIterator(); + } + return null; } /** diff --git a/src/org/apache/fop/fo/flow/BidiOverride.java b/src/org/apache/fop/fo/flow/BidiOverride.java index f9a8b661b..280dff4d9 100644 --- a/src/org/apache/fop/fo/flow/BidiOverride.java +++ b/src/org/apache/fop/fo/flow/BidiOverride.java @@ -85,7 +85,7 @@ public class BidiOverride extends FObjMixed { BidiLayoutManager(FObj obj, LeafNodeLayoutManager cLM) { super(obj); childs = new ArrayList(); - for (int count = cLM.size() - 1; count >= 0; count--) { +/* for (int count = cLM.size() - 1; count >= 0; count--) { InlineArea ia = cLM.get(count); if (ia instanceof Word) { // reverse word @@ -95,7 +95,7 @@ public class BidiOverride extends FObjMixed { } childs.add(ia); } - } +*/ } public int size() { return childs.size(); diff --git a/src/org/apache/fop/fo/flow/ExternalGraphic.java b/src/org/apache/fop/fo/flow/ExternalGraphic.java index 561f95ac9..bef021138 100644 --- a/src/org/apache/fop/fo/flow/ExternalGraphic.java +++ b/src/org/apache/fop/fo/flow/ExternalGraphic.java @@ -48,6 +48,8 @@ public class ExternalGraphic extends FObj { public void addLayoutManager(List list) { LeafNodeLayoutManager lm = new LeafNodeLayoutManager(this); lm.setCurrentArea(getInlineArea()); + lm.setAlignment(properties.get("vertical-align").getEnum()); + lm.setLead(viewHeight); list.add(lm); } @@ -63,9 +65,6 @@ public class ExternalGraphic extends FObj { vp.setClip(clip); vp.setContentPosition(placement); vp.setOffset(0); - vp.info = new LayoutInfo(); - vp.info.alignment = properties.get("vertical-align").getEnum(); - vp.info.lead = vp.getHeight(); return vp; } diff --git a/src/org/apache/fop/fo/flow/InstreamForeignObject.java b/src/org/apache/fop/fo/flow/InstreamForeignObject.java index 398293f43..47a50453d 100644 --- a/src/org/apache/fop/fo/flow/InstreamForeignObject.java +++ b/src/org/apache/fop/fo/flow/InstreamForeignObject.java @@ -57,6 +57,8 @@ public class InstreamForeignObject extends FObj { public void addLayoutManager(List list) { LeafNodeLayoutManager lm = new LeafNodeLayoutManager(this); lm.setCurrentArea(getInlineArea()); + lm.setAlignment(properties.get("vertical-align").getEnum()); + lm.setLead(areaCurrent.getHeight()); list.add(lm); } @@ -247,9 +249,6 @@ public class InstreamForeignObject extends FObj { areaCurrent.setContentPosition(placement); areaCurrent.setClip(clip); areaCurrent.setOffset(0); - areaCurrent.info = new LayoutInfo(); - areaCurrent.info.alignment = properties.get("vertical-align").getEnum(); - areaCurrent.info.lead = areaCurrent.getHeight(); return areaCurrent; } diff --git a/src/org/apache/fop/fo/flow/Leader.java b/src/org/apache/fop/fo/flow/Leader.java index 5e5c4e49f..d4e56a3d1 100644 --- a/src/org/apache/fop/fo/flow/Leader.java +++ b/src/org/apache/fop/fo/flow/Leader.java @@ -34,9 +34,7 @@ public class Leader extends FObjMixed { public void addLayoutManager(List list) { list.add(new LeafNodeLayoutManager(this) { - public InlineArea get(int index) { - if(index > 0) - return null; + public InlineArea get() { int contentIPD = parentLM.getContentIPD(); return getInlineArea(contentIPD); } |