import org.apache.fop.layoutmgr.KnuthElement;
import org.apache.fop.layoutmgr.KnuthGlue;
import org.apache.fop.layoutmgr.KnuthPenalty;
+import org.apache.fop.layoutmgr.KnuthSequence;
import org.apache.fop.layoutmgr.LayoutContext;
import org.apache.fop.layoutmgr.LeafPosition;
import org.apache.fop.layoutmgr.Position;
int alignment) {
MinOptMax ipd;
curArea = get(context);
- LinkedList returnList = new LinkedList();
+ KnuthSequence seq = new KnuthSequence(true);
if (curArea == null) {
setFinished(true);
// node is a fo:Character
if (letterSpaceIPD.min == letterSpaceIPD.max) {
// constant letter space, only return a box
- returnList.add(new KnuthInlineBox(areaInfo.ipdArea.opt, areaInfo.lead,
+ seq.add(new KnuthInlineBox(areaInfo.ipdArea.opt, areaInfo.lead,
areaInfo.total, areaInfo.middle,
new LeafPosition(this, 0), false));
} else {
// at the moment the character is supposed to have no letter spaces,
// but returning this sequence allows us to change only one element
// if addALetterSpaceTo() is called
- returnList.add(new KnuthInlineBox(areaInfo.ipdArea.opt, areaInfo.lead,
+ seq.add(new KnuthInlineBox(areaInfo.ipdArea.opt, areaInfo.lead,
areaInfo.total, areaInfo.middle,
new LeafPosition(this, 0), false));
- returnList.add(new KnuthPenalty(0, KnuthElement.INFINITE, false,
+ seq.add(new KnuthPenalty(0, KnuthElement.INFINITE, false,
new LeafPosition(this, -1), true));
- returnList.add(new KnuthGlue(0, 0, 0,
+ seq.add(new KnuthGlue(0, 0, 0,
new LeafPosition(this, -1), true));
- returnList.add(new KnuthInlineBox(0, 0, 0, 0,
+ seq.add(new KnuthInlineBox(0, 0, 0, 0,
new LeafPosition(this, -1), true));
}
+ LinkedList returnList = new LinkedList();
+ returnList.add(seq);
setFinished(true);
return returnList;
}
if (returnedList.size() == 0) {
//Inline part of the footnote is empty. Need to send back an auxiliary
//zero-width, zero-height inline box so the footnote gets painted.
- returnedList.add(new KnuthInlineBox(0, 0, 0, 0, null, true));
+ KnuthSequence seq = new KnuthSequence(true);
+ seq.add(new KnuthInlineBox(0, 0, 0, 0, null, true));
+ returnedList.add(seq);
}
setFinished(true);
import org.apache.fop.layoutmgr.KnuthGlue;
import org.apache.fop.layoutmgr.KnuthPenalty;
import org.apache.fop.layoutmgr.KnuthPossPosIter;
+import org.apache.fop.layoutmgr.KnuthSequence;
import org.apache.fop.layoutmgr.LayoutContext;
import org.apache.fop.layoutmgr.LeafPosition;
import org.apache.fop.layoutmgr.Position;
int alignment) {
MinOptMax ipd;
curArea = get(context);
- LinkedList returnList = new LinkedList();
+ KnuthSequence seq = new KnuthSequence(true);
if (curArea == null) {
setFinished(true);
lead, total, middle);
// node is a fo:Leader
- returnList.add(new KnuthInlineBox(0, areaInfo.lead, areaInfo.total,
+ seq.add(new KnuthInlineBox(0, areaInfo.lead, areaInfo.total,
areaInfo.middle,
new LeafPosition(this, -1), true));
- returnList.add(new KnuthPenalty(0, KnuthElement.INFINITE, false,
+ seq.add(new KnuthPenalty(0, KnuthElement.INFINITE, false,
new LeafPosition(this, -1), true));
- returnList.add
+ seq.add
(new KnuthGlue(areaInfo.ipdArea.opt,
areaInfo.ipdArea.max - areaInfo.ipdArea.opt,
areaInfo.ipdArea.opt - areaInfo.ipdArea.min,
new LeafPosition(this, 0), false));
- returnList.add(new KnuthInlineBox(0, areaInfo.lead, areaInfo.total,
+ seq.add(new KnuthInlineBox(0, areaInfo.lead, areaInfo.total,
areaInfo.middle,
new LeafPosition(this, -1), true));
+ LinkedList returnList = new LinkedList();
+ returnList.add(seq);
setFinished(true);
return returnList;
}
import org.apache.fop.area.inline.InlineArea;
import org.apache.fop.fo.FObj;
import org.apache.fop.layoutmgr.AbstractLayoutManager;
+import org.apache.fop.layoutmgr.KnuthSequence;
import org.apache.fop.layoutmgr.LayoutContext;
import org.apache.fop.layoutmgr.LeafPosition;
import org.apache.fop.layoutmgr.Position;
// node is a fo:ExternalGraphic, fo:InstreamForeignObject,
// fo:PageNumber or fo:PageNumberCitation
- LinkedList returnList = new LinkedList();
- returnList.add(new KnuthInlineBox(areaInfo.ipdArea.opt, areaInfo.lead,
+ KnuthSequence seq = new KnuthSequence(true);
+ seq.add(new KnuthInlineBox(areaInfo.ipdArea.opt, areaInfo.lead,
areaInfo.total, areaInfo.middle,
new LeafPosition(this, 0), false));
+ LinkedList returnList = new LinkedList();
+ returnList.add(seq);
setFinished(true);
return returnList;
}