]> source.dussan.org Git - xmlgraphics-fop.git/commitdiff
Fix for ClassCastException
authorJeremias Maerki <jeremias@apache.org>
Thu, 20 Oct 2005 08:09:22 +0000 (08:09 +0000)
committerJeremias Maerki <jeremias@apache.org>
Thu, 20 Oct 2005 08:09:22 +0000 (08:09 +0000)
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/branches/Temp_SpaceResolution@326855 13f79535-47bb-0310-9956-ffa450edef68

src/java/org/apache/fop/layoutmgr/BlockStackingLayoutManager.java

index 76291a81e1e79812ce744c3bd6e7a781208741fd..ac0abc26e4b01db43addf04c1c23b568bbfffa63 100644 (file)
@@ -255,8 +255,7 @@ public abstract class BlockStackingLayoutManager extends AbstractLayoutManager
             }
             if (returnedList != null
                     && returnedList.size() == 1
-                    && ((KnuthElement) returnedList.getFirst()).isPenalty()
-                    && ((KnuthPenalty) returnedList.getFirst()).getP() == -KnuthElement.INFINITE) {
+                    && ((ListElement) returnedList.getFirst()).isForcedBreak()) {
                 // a descendant of this block has break-before
                 if (returnList.size() == 0) {
                     // the first child (or its first child ...) has