From aa65b4ba4070afab4b925fd292b6a55d0067844e Mon Sep 17 00:00:00 2001 From: Glen Mazza Date: Tue, 27 Jul 2004 03:01:33 +0000 Subject: Redefining "isOutOfLineFODescendant" to include cases where FObj itself is and O-o-L FO. git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@197841 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/fop/fo/FObj.java | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'src/java/org/apache') diff --git a/src/java/org/apache/fop/fo/FObj.java b/src/java/org/apache/fop/fo/FObj.java index a6d3739c4..ac37a55b3 100644 --- a/src/java/org/apache/fop/fo/FObj.java +++ b/src/java/org/apache/fop/fo/FObj.java @@ -58,8 +58,9 @@ public class FObj extends FONode implements Constants { /** During input FO validation, certain FO's are not valid as child nodes if they would be a descendant of an Out Of Line - Formatting Object as defined in specification. - See Section 6.2 of 1.0/1.2 spec for more information. + Formatting Object as defined in specification (See Sect. 6.2 + of spec.) This value is also set to true if this object + itself is an Out Of Line FO. */ protected boolean isOutOfLineFODescendant = false; @@ -76,9 +77,9 @@ public class FObj extends FONode implements Constants { if (parent != null && parent instanceof FObj) { if (((FObj)parent).getIsOutOfLineFODescendant() == true) { isOutOfLineFODescendant = true; - } else if (parent.getName().equals("fo:float") - || parent.getName().equals("fo:footnote") - || parent.getName().equals("fo:footnote-body")) { + } else if ("fo:float".equals(getName()) + || "fo:footnote".equals(getName()) + || "fo:footnote-body".equals(getName())) { isOutOfLineFODescendant = true; } } -- cgit v1.2.3