From 7200fc21fe794f1889d6251f1bed70b3249c3ab9 Mon Sep 17 00:00:00 2001 From: Vincent Hennebert Date: Fri, 27 Aug 2010 14:02:34 +0000 Subject: [PATCH] Fixed indentation git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@990155 13f79535-47bb-0310-9956-ffa450edef68 --- .../org/apache/fop/layoutmgr/PageBreakingAlgorithm.java | 4 ++-- .../fop/layoutmgr/inline/CharacterLayoutManager.java | 9 ++++----- .../apache/fop/layoutmgr/inline/LineLayoutManager.java | 5 +++-- src/java/org/apache/fop/render/ps/PSBorderPainter.java | 2 +- 4 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/java/org/apache/fop/layoutmgr/PageBreakingAlgorithm.java b/src/java/org/apache/fop/layoutmgr/PageBreakingAlgorithm.java index e0b0cae11..7e54cbe43 100644 --- a/src/java/org/apache/fop/layoutmgr/PageBreakingAlgorithm.java +++ b/src/java/org/apache/fop/layoutmgr/PageBreakingAlgorithm.java @@ -514,7 +514,7 @@ class PageBreakingAlgorithm extends BreakingAlgorithm { footnoteElementIndex = getFootnoteList(footnoteListIndex).size() - 1; } else if (((canDeferOldFN = canDeferOldFootnotes // CSOK: InnerAssignment - (pageNode, elementIndex)) + (pageNode, elementIndex)) || newFootnotes) && (footnoteSplit = getFootnoteSplit // CSOK: InnerAssignment (pageNode, getLineWidth(activeNode.line) - actualWidth, @@ -1125,7 +1125,7 @@ class PageBreakingAlgorithm extends BreakingAlgorithm { */ protected void addNode(int line, KnuthNode node) { if (node.position < par.size() - 1 && line > 0 - && (ipdDifference = compareIPDs(line - 1)) != 0) { // CSOK: InnerAssignment + && (ipdDifference = compareIPDs(line - 1)) != 0) { // CSOK: InnerAssignment log.trace("IPD changes at page " + line); if (bestNodeForIPDChange == null || node.totalDemerits < bestNodeForIPDChange.totalDemerits) { diff --git a/src/java/org/apache/fop/layoutmgr/inline/CharacterLayoutManager.java b/src/java/org/apache/fop/layoutmgr/inline/CharacterLayoutManager.java index ed22886a4..66e162692 100644 --- a/src/java/org/apache/fop/layoutmgr/inline/CharacterLayoutManager.java +++ b/src/java/org/apache/fop/layoutmgr/inline/CharacterLayoutManager.java @@ -194,9 +194,8 @@ public class CharacterLayoutManager extends LeafNodeLayoutManager { areaInfo.alignmentContext, notifyPos(new LeafPosition(this, 0)), false)); if (areaInfo.bHyphenated) { - returnList.add - (new KnuthPenalty(hyphIPD, KnuthPenalty.FLAGGED_PENALTY, true, - new LeafPosition(this, -1), false)); + returnList.add(new KnuthPenalty(hyphIPD, KnuthPenalty.FLAGGED_PENALTY, true, + new LeafPosition(this, -1), false)); } } else { // adjustable letter space @@ -207,8 +206,8 @@ public class CharacterLayoutManager extends LeafNodeLayoutManager { new LeafPosition(this, -1), true)); returnList.add(new KnuthGlue(letterSpaceIPD.mult(areaInfo.iLScount), new LeafPosition(this, -1), true)); - returnList.add - (new KnuthInlineBox(0, null, notifyPos(new LeafPosition(this, -1)), true)); + returnList.add ( + new KnuthInlineBox(0, null, notifyPos(new LeafPosition(this, -1)), true)); if (areaInfo.bHyphenated) { returnList.add(new KnuthPenalty(hyphIPD, KnuthPenalty.FLAGGED_PENALTY, true, new LeafPosition(this, -1), false)); diff --git a/src/java/org/apache/fop/layoutmgr/inline/LineLayoutManager.java b/src/java/org/apache/fop/layoutmgr/inline/LineLayoutManager.java index 04978ad54..83d286c15 100644 --- a/src/java/org/apache/fop/layoutmgr/inline/LineLayoutManager.java +++ b/src/java/org/apache/fop/layoutmgr/inline/LineLayoutManager.java @@ -356,7 +356,7 @@ public class LineLayoutManager extends InlineStackingLayoutManager indent += (textAlign == Constants.EN_CENTER) ? difference / 2 : (textAlign == Constants.EN_END) ? difference : 0; indent += (bestActiveNode.line == 1 && indentFirstPart && isFirstInBlock) - ? textIndent : 0; + ? textIndent : 0; double ratio = (textAlign == Constants.EN_JUSTIFY || difference < 0 && -difference <= bestActiveNode.availableShrink) ? bestActiveNode.adjustRatio : 0; @@ -711,7 +711,8 @@ public class LineLayoutManager extends InlineStackingLayoutManager // finish last paragraph if it was closed with a linefeed if (lastElement.isPenalty() - && ((KnuthPenalty) lastElement).getPenalty() == -KnuthPenalty.INFINITE) { + && ((KnuthPenalty) lastElement).getPenalty() + == -KnuthPenalty.INFINITE) { // a penalty item whose value is -inf // represents a preserved linefeed, // which forces a line break diff --git a/src/java/org/apache/fop/render/ps/PSBorderPainter.java b/src/java/org/apache/fop/render/ps/PSBorderPainter.java index 2d881571a..1e2964eed 100644 --- a/src/java/org/apache/fop/render/ps/PSBorderPainter.java +++ b/src/java/org/apache/fop/render/ps/PSBorderPainter.java @@ -75,7 +75,7 @@ public class PSBorderPainter extends BorderPainter { PSGenerator gen, float x1, float y1, float x2, float y2, boolean horz, // CSOK: JavadocMethod boolean startOrBefore, int style, Color col) // CSOK: JavadocMethod - throws IOException { // CSOK: JavadocMethod + throws IOException { // CSOK: JavadocMethod float w = x2 - x1; float h = y2 - y1; if ((w < 0) || (h < 0)) { -- 2.39.5