diff options
author | Simon Pepping <spepping@apache.org> | 2005-12-27 08:40:09 +0000 |
---|---|---|
committer | Simon Pepping <spepping@apache.org> | 2005-12-27 08:40:09 +0000 |
commit | 7fde5817bc810b39a2e5c3bec9e4f3fa25ffe557 (patch) | |
tree | 37597cde67f27c77f894d790015c45001d56e342 /src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java | |
parent | 274439d94f0f26ad82650079fb924361089d3b5a (diff) | |
download | xmlgraphics-fop-7fde5817bc810b39a2e5c3bec9e4f3fa25ffe557.tar.gz xmlgraphics-fop-7fde5817bc810b39a2e5c3bec9e4f3fa25ffe557.zip |
I generalized several casts from KnuthElement to ListElement. This
removes a number of ClassCastExceptions in some files with inline
block content.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@359189 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java')
-rw-r--r-- | src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java b/src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java index 6932b7600..788339790 100644 --- a/src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java +++ b/src/java/org/apache/fop/layoutmgr/InlineKnuthSequence.java @@ -70,11 +70,11 @@ public class InlineKnuthSequence extends KnuthSequence { return false; } // does the first element of the first paragraph add to an existing word? - KnuthElement lastOldElement, firstNewElement; + ListElement lastOldElement, firstNewElement; lastOldElement = getLast(); firstNewElement = sequence.getElement(0); - if (firstNewElement.isBox() && !firstNewElement.isAuxiliary() - && lastOldElement.isBox() && lastOldElement.getW() != 0) { + if (firstNewElement.isBox() && !((KnuthElement) firstNewElement).isAuxiliary() + && lastOldElement.isBox() && ((KnuthElement) lastOldElement).getW() != 0) { addALetterSpace(); } addAll(sequence); |