diff options
author | Luca Furini <lfurini@apache.org> | 2005-09-08 10:47:57 +0000 |
---|---|---|
committer | Luca Furini <lfurini@apache.org> | 2005-09-08 10:47:57 +0000 |
commit | 1c5cae7362ae33673b79090a2e2ae668babcb9da (patch) | |
tree | 1de36c56de9f2e5bb1f7f06fdcd96e2ed5c12795 /src/java | |
parent | 87185a02acb55a5cf950f27cff44cab34e47bd7a (diff) | |
download | xmlgraphics-fop-1c5cae7362ae33673b79090a2e2ae668babcb9da.tar.gz xmlgraphics-fop-1c5cae7362ae33673b79090a2e2ae668babcb9da.zip |
Removing trailing spaces at the end of text areas: this is done by storing the Position, whose value points to the AreaInfo created for a space, inside the glue element that is ignored if there is a line break.
This fixes item 2) in bug 36533.
git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@279551 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'src/java')
-rw-r--r-- | src/java/org/apache/fop/layoutmgr/inline/TextLayoutManager.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/java/org/apache/fop/layoutmgr/inline/TextLayoutManager.java b/src/java/org/apache/fop/layoutmgr/inline/TextLayoutManager.java index 7e709a93b..0e3667798 100644 --- a/src/java/org/apache/fop/layoutmgr/inline/TextLayoutManager.java +++ b/src/java/org/apache/fop/layoutmgr/inline/TextLayoutManager.java @@ -458,14 +458,14 @@ public class TextLayoutManager extends LeafNodeLayoutManager { wordSpaceIPD, false)); sequence.add (new KnuthGlue(0, 3 * LineLayoutManager.DEFAULT_SPACE_WIDTH, 0, - new LeafPosition(this, vecAreaInfo.size() - 1), false)); + new LeafPosition(this, -1), false)); sequence.add (new KnuthPenalty(0, 0, false, new LeafPosition(this, -1), true)); sequence.add (new KnuthGlue(wordSpaceIPD.opt, - 6 * LineLayoutManager.DEFAULT_SPACE_WIDTH, 0, - new LeafPosition(this, -1), true)); + new LeafPosition(this, vecAreaInfo.size() - 1), true)); sequence.add (new KnuthInlineBox(0, 0, 0, 0, new LeafPosition(this, -1), true)); @@ -486,14 +486,14 @@ public class TextLayoutManager extends LeafNodeLayoutManager { wordSpaceIPD, false)); sequence.add (new KnuthGlue(0, 3 * wordSpaceIPD.opt, 0, - new LeafPosition(this, vecAreaInfo.size() - 1), false)); + new LeafPosition(this, -1), false)); sequence.add (new KnuthPenalty(0, 0, false, new LeafPosition(this, -1), true)); sequence.add (new KnuthGlue(wordSpaceIPD.opt, - 3 * wordSpaceIPD.opt, 0, - new LeafPosition(this, -1), true)); + new LeafPosition(this, vecAreaInfo.size() - 1), true)); iNextStart ++; break; |