jfig.utils
Class LP2.StackBox

java.lang.Object
  extended byjfig.utils.LP2.Box
      extended byjfig.utils.LP2.StackBox
Enclosing class:
LP2

public class LP2.StackBox
extends LP2.Box

a StackBox manages three entries for boxes stacked one upon each other: bottom, center, and top. It is used for commands like \over or \accents When constructing a StackBox, we expect that the (x,y) origin of the StackBox is set; this will often correspond to the origin of the centerBox.


Field Summary
protected  int align
           
protected  LP2.Box bottomBox
           
protected  LP2.Box centerBox
           
protected  LP2.Box topBox
           
protected  int Y_SPACING
           
 
Fields inherited from class jfig.utils.LP2.Box
a, comment, d, next, parent, prev, w, x, y
 
Constructor Summary
LP2.StackBox()
           
 
Method Summary
 void convertToFig(FigCompound parent)
          construct a FIG object from this Box and all its child boxes and put those as members into the specified FigCompound group object.
 int getAlignment()
           
 LP2.Box getBottomBox()
           
 LP2.Box getCenterbox()
           
 LP2.Box getTopBox()
           
 void measure()
          measure this StackBox including the current alignment settings.
 void move(int dx, int dy)
           
 void setAlignment(int _align)
           
 void setBottomBox(LP2.Box b)
           
 void setCenterBox(LP2.Box b)
           
 void setTopBox(LP2.Box b)
           
 
Methods inherited from class jfig.utils.LP2.Box
append, dump, getA, getAbutmentPoint, getBounds, getComment, getD, getFigRectangle, getNextBox, getOrigin, getParent, getPrevBox, getW, getX, getY, moveTo, setA, setComment, setD, setNextBox, setOrigin, setParent, setPrevBox, setW, setX, setY, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

topBox

protected LP2.Box topBox

centerBox

protected LP2.Box centerBox

bottomBox

protected LP2.Box bottomBox

align

protected int align

Y_SPACING

protected int Y_SPACING
Constructor Detail

LP2.StackBox

public LP2.StackBox()
Method Detail

getTopBox

public LP2.Box getTopBox()

getCenterbox

public LP2.Box getCenterbox()

getBottomBox

public LP2.Box getBottomBox()

setTopBox

public void setTopBox(LP2.Box b)

setCenterBox

public void setCenterBox(LP2.Box b)

setBottomBox

public void setBottomBox(LP2.Box b)

setAlignment

public void setAlignment(int _align)

getAlignment

public int getAlignment()

move

public void move(int dx,
                 int dy)
Overrides:
move in class LP2.Box

measure

public void measure()
measure this StackBox including the current alignment settings. Note: we expect that a valid (x,y) origin for this box has been set.

Overrides:
measure in class LP2.Box

convertToFig

public void convertToFig(FigCompound parent)
Description copied from class: LP2.Box
construct a FIG object from this Box and all its child boxes and put those as members into the specified FigCompound group object. Check the display_boxes flag to decide whether to generate bounding boxes, too.

Overrides:
convertToFig in class LP2.Box