diff options
author | Jeremias Maerki <jeremias@apache.org> | 2008-07-28 15:05:14 +0000 |
---|---|---|
committer | Jeremias Maerki <jeremias@apache.org> | 2008-07-28 15:05:14 +0000 |
commit | e016f209941db98ef58fd4e2efa12caeb4875ce6 (patch) | |
tree | 1af8f696f7885f0c8aa3349518a16e37bf786db4 /src/java/org/apache/fop/render/afp | |
parent | 3307e9495037a527348aa0153dd8c5e1b43afdcb (diff) | |
download | xmlgraphics-fop-e016f209941db98ef58fd4e2efa12caeb4875ce6.tar.gz xmlgraphics-fop-e016f209941db98ef58fd4e2efa12caeb4875ce6.zip |
Reverted revision 670341 and replaced it with a different solution as discussed:
addCharacters() is now deprecated and called by the new characters() method which uses start/length instead of start/end.
Fixed bugs in the AFP and PS extensions (ArrayIndexOutOfBoundsExceptions). They were not properly changed when the interface changed.
Discussion: http://markmail.org/message/pdgzf6odxrnhflby
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@680378 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java/org/apache/fop/render/afp')
-rw-r--r-- | src/java/org/apache/fop/render/afp/extensions/AbstractAFPExtensionObject.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/java/org/apache/fop/render/afp/extensions/AbstractAFPExtensionObject.java b/src/java/org/apache/fop/render/afp/extensions/AbstractAFPExtensionObject.java index 364889b29..a92687aab 100644 --- a/src/java/org/apache/fop/render/afp/extensions/AbstractAFPExtensionObject.java +++ b/src/java/org/apache/fop/render/afp/extensions/AbstractAFPExtensionObject.java @@ -20,13 +20,14 @@ package org.apache.fop.render.afp.extensions; // FOP +import org.xml.sax.Attributes; +import org.xml.sax.Locator; + import org.apache.fop.apps.FOPException; import org.apache.fop.fo.FONode; import org.apache.fop.fo.PropertyList; import org.apache.fop.fo.ValidationException; import org.apache.fop.fo.extensions.ExtensionAttachment; -import org.xml.sax.Attributes; -import org.xml.sax.Locator; /** * Base class for the AFP-specific extension elements. @@ -60,9 +61,9 @@ public abstract class AbstractAFPExtensionObject extends FONode { } /** {@inheritDoc} */ - protected void addCharacters(char[] data, int start, int end, + protected void characters(char[] data, int start, int length, PropertyList pList, Locator locator) { - setupCode.setContent(new String(data, start, end - start)); + setupCode.setContent(new String(data, start, length)); } /** {@inheritDoc} */ |