Package com.openhtmltopdf.layout
Class VerticalAlignContext
- java.lang.Object
-
- com.openhtmltopdf.layout.VerticalAlignContext
-
public class VerticalAlignContext extends java.lang.ObjectThis class performs the real work of vertically positioning inline boxes within a line (i.e. implementing the vertical-align property). Because of the requirements of vertical-align: top/bottom, aVerticalAlignContextis actually a tree ofVerticalAlignContextobjects which all must be taken into consideration when aligning content.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classVerticalAlignContext.ChildContextData
-
Field Summary
Fields Modifier and Type Field Description private java.util.List<VerticalAlignContext.ChildContextData>_childrenprivate int_inlineBottomprivate boolean_inlineBottomSetprivate int_inlineTopprivate boolean_inlineTopSetprivate java.util.List<InlineBoxMeasurements>_measurementsprivate int_paintingBottomprivate boolean_paintingBottomSetprivate int_paintingTopprivate boolean_paintingTopSetprivate VerticalAlignContext_parent
-
Constructor Summary
Constructors Constructor Description VerticalAlignContext()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidalignChildren()VerticalAlignContextcreateChild(Box root)java.util.List<VerticalAlignContext.ChildContextData>getChildren()intgetInlineBottom()intgetInlineTop()intgetLineBoxHeight()intgetPaintingBottom()intgetPaintingTop()VerticalAlignContextgetParent()InlineBoxMeasurementsgetParentMeasurements()private VerticalAlignContextgetRoot()private voidmerge(VerticalAlignContext context)private voidmoveTrackedValues(int ty)voidpopMeasurements()voidpushMeasurements(InlineBoxMeasurements measurements)voidsetInitialMeasurements(InlineBoxMeasurements measurements)voidsetParent(VerticalAlignContext parent)voidupdateInlineBottom(int inlineBottom)voidupdateInlineTop(int inlineTop)voidupdatePaintingBottom(int paintingBottom)voidupdatePaintingTop(int paintingTop)
-
-
-
Field Detail
-
_measurements
private final java.util.List<InlineBoxMeasurements> _measurements
-
_inlineTop
private int _inlineTop
-
_inlineTopSet
private boolean _inlineTopSet
-
_inlineBottom
private int _inlineBottom
-
_inlineBottomSet
private boolean _inlineBottomSet
-
_paintingTop
private int _paintingTop
-
_paintingTopSet
private boolean _paintingTopSet
-
_paintingBottom
private int _paintingBottom
-
_paintingBottomSet
private boolean _paintingBottomSet
-
_children
private java.util.List<VerticalAlignContext.ChildContextData> _children
-
_parent
private VerticalAlignContext _parent
-
-
Method Detail
-
moveTrackedValues
private void moveTrackedValues(int ty)
-
getInlineBottom
public int getInlineBottom()
-
getInlineTop
public int getInlineTop()
-
updateInlineTop
public void updateInlineTop(int inlineTop)
-
updatePaintingTop
public void updatePaintingTop(int paintingTop)
-
updateInlineBottom
public void updateInlineBottom(int inlineBottom)
-
updatePaintingBottom
public void updatePaintingBottom(int paintingBottom)
-
getLineBoxHeight
public int getLineBoxHeight()
-
pushMeasurements
public void pushMeasurements(InlineBoxMeasurements measurements)
-
getParentMeasurements
public InlineBoxMeasurements getParentMeasurements()
-
popMeasurements
public void popMeasurements()
-
getPaintingBottom
public int getPaintingBottom()
-
getPaintingTop
public int getPaintingTop()
-
createChild
public VerticalAlignContext createChild(Box root)
-
getChildren
public java.util.List<VerticalAlignContext.ChildContextData> getChildren()
-
getParent
public VerticalAlignContext getParent()
-
setParent
public void setParent(VerticalAlignContext parent)
-
getRoot
private VerticalAlignContext getRoot()
-
merge
private void merge(VerticalAlignContext context)
-
alignChildren
public void alignChildren()
-
setInitialMeasurements
public void setInitialMeasurements(InlineBoxMeasurements measurements)
-
-