]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
No more warnings about unexpected FOText inside markers.
authorJeremias Maerki <jeremias@apache.org>
Mon, 18 Jul 2005 10:51:00 +0000 (10:51 +0000)
committerJeremias Maerki <jeremias@apache.org>
Mon, 18 Jul 2005 10:51:00 +0000 (10:51 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@219464 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/fo/FOText.java

index 393c20871f4055eb16bc0cc4daf63ab630a8e3e1..4014e2fb80b55ac1ee2fd65605ef2350fe576d7d 100644 (file)
@@ -31,6 +31,8 @@ import org.apache.fop.fo.properties.CommonHyphenation;
 import org.apache.fop.fo.properties.CommonTextDecoration;
 import org.apache.fop.fo.properties.Property;
 import org.apache.fop.fo.properties.SpaceProperty;
+
+// SAX
 import org.xml.sax.Locator;
 
 /**
@@ -214,8 +216,11 @@ public class FOText extends FONode {
             ancestorFONode = ancestorFONode.parent;
             if (ancestorFONode instanceof org.apache.fop.fo.pagination.Title) {
                 return;
+            } else if (ancestorFONode instanceof org.apache.fop.fo.flow.Marker) {
+                return;
             } else if (ancestorFONode instanceof Root) {
-                getLogger().warn("Unexpected: fo:text with no fo:block ancestor");
+                getLogger().warn("Unexpected: fo:text with no fo:block ancestor. The text is: " 
+                        + new String(ca));
                 return;
             } else if (ancestorFONode instanceof Block) {
                 this.ancestorBlock = (Block)ancestorFONode;