Package com.openhtmltopdf.render
Class AnonymousBlockBox
- java.lang.Object
-
- com.openhtmltopdf.render.Box
-
- com.openhtmltopdf.render.BlockBox
-
- com.openhtmltopdf.render.AnonymousBlockBox
-
- All Implemented Interfaces:
InlinePaintable,Styleable,DisplayListItem
public class AnonymousBlockBox extends BlockBox
An anonymous block box as defined in the CSS spec. This class is only used when wrapping inline content in a block box in order to ensure that a block box only ever contains either block or inline content. Other anonymous block boxes create aBlockBoxdirectly with the anonymous property is true.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.openhtmltopdf.render.BlockBox
BlockBox.MarginCollapseResult
-
-
Field Summary
-
Fields inherited from class com.openhtmltopdf.render.BlockBox
CONTENT_BLOCK, CONTENT_EMPTY, CONTENT_INLINE, CONTENT_UNKNOWN, NO_BASELINE, POSITION_BOTH, POSITION_HORIZONTALLY, POSITION_VERTICALLY
-
Fields inherited from class com.openhtmltopdf.render.Box
CHILDREN_FLUX, DONE, DUMP_LAYOUT, DUMP_RENDER, FLUX, LINE_SEPARATOR, NOTHING
-
-
Constructor Summary
Constructors Constructor Description AnonymousBlockBox(Element element)
-
Method Summary
Modifier and Type Method Description BlockBoxcopyOf()Boxfind(CssContext cssCtx, int absX, int absY, boolean findAnonymous)intgetContentWidth()List<InlineBox>getOpenInlineBoxes()booleanisMayCollapseMarginsWithChildren()booleanisSkipWhenCollapsingMargins()voidlayout(LayoutContext c)voidprovideSiblingMarginToFloats(int margin)voidsetOpenInlineBoxes(List<InlineBox> openInlineBoxes)voidstyleText(LayoutContext c)-
Methods inherited from class com.openhtmltopdf.render.BlockBox
appendPositioningInfo, calcBaseline, calcBreakAtLineContext, calcCanvasLocation, calcChildLocations, calcChildPaintingInfo, calcDimensions, calcDimensions, calcInitialBreakAtLine, calcInitialFloatedCanvasLocation, calcInlineBaseline, calcLayoutHeight, calcMinMaxWidth, checkPageContext, createMarkerData, dump, ensureChildren, findLastNthLineBox, findOffset, getAvailableWidth, getChildrenContentType, getChildrenHeight, getCSSFitToWidth, getCSSHeight, getCSSWidth, getCSSWidth, getDocumentParent, getExtraBoxDescription, getFirstLetterStyle, getFirstLineStyle, getFloatedBoxData, getInlineContent, getLineBox, getListCounter, getMarkerData, getMaxWidth, getMinWidth, getNextCollapsableSibling, getPageClearance, getPaintingClipEdge, getPersistentBFC, getReplacedElement, getStaticEquivalent, initStaticPos, isAllowHeightToShrink, isAutoHeight, isBottomMarginCalculated, isContainsInlineContent, isCurrentBreakAtLineContext, isFixedWidthAdvisoryOnly, isFloated, isFromCaptionedTable, isInline, isInlineBlock, isInMainFlow, isListItem, isMinMaxCalculated, isNeedPageClear, isNeedsClipOnPaint, isNeedsKeepWithInline, isPageBreakNeededBecauseOfMinHeight, isReplaced, isTopMarginCalculated, layout, layoutChildren, layoutInlineChildren, paintDebugOutline, paintInline, paintListMarker, positionAbsolute, positionAbsoluteOnPage, propagateExtraSpace, reset, resolveAutoMargins, setBottomMarginCalculated, setChildrenContentType, setChildrenHeight, setDimensionsCalculated, setElement, setFirstLetterStyle, setFirstLineStyle, setFloatedBoxData, setFromCaptionedTable, setInlineContent, setListCounter, setMarkerData, setMaxWidth, setMinMaxCalculated, setMinWidth, setNeedPageClear, setNeedShrinkToFitCalculatation, setPersistentBFC, setReplacedElement, setStaticEquivalent, setTopMarginCalculated, shouldBeReplaced, styleText, toString
-
Methods inherited from class com.openhtmltopdf.render.Box
addAllChildren, addChild, addChildForLayout, analyzePageBreaks, calcPaintingInfo, collectText, connectChildrenToCurrentLayer, crossesPageBreak, detach, dumpBoxes, exportPageBoxText, exportText, forcePageBreakAfter, forcePageBreakBefore, getAbsoluteClipBox, getAbsX, getAbsY, getAccessibilityObject, getBorder, getBorderBox, getBorderBoxHeight, getBorderBoxWidth, getBorderEdge, getBorderSides, getBoxDimensions, getChild, getChildCount, getChildIterator, getChildren, getChildrenClipEdge, getClipBox, getContainingBlock, getContainingBlockWidth, getContainingLayer, getContentAreaEdge, getEffBackgroundColor, getEffectiveWidth, getElement, getElementBoxes, getHeight, getIndex, getLayer, getLeftMBP, getMargin, getMarginBorderPadding, getMarginEdge, getMarginEdge, getNext, getNextSibling, getPadding, getPaddingEdge, getPaddingWidth, getPaintingBorderEdge, getPaintingInfo, getPaintingPaddingEdge, getParent, getParentClipBox, getPrevious, getPreviousSibling, getPseudoElementOrClass, getRelativeOffset, getRestyleTarget, getRightMBP, getState, getStyle, getStyleMargin, getStyleMargin, getTx, getTy, getWidth, getX, getY, hasNonTextContent, hasRootElementBackground, initContainingLayer, intersects, isAnonymous, isBody, isContainedInMarginBox, isFlowingColumnBox, isInDocumentFlow, isInitialContainingBlock, isMarginAreaRoot, isRoot, isStyled, moveIfGreater, paintBackground, paintBorder, paintRootElementBackground, positionRelative, removeAllChildren, removeChild, removeChild, resetChildren, resetChildren, resetTopMargin, restyle, restyleChildren, setAbsX, setAbsY, setAccessiblityObject, setAnonymous, setBorderBoxHeight, setBorderBoxWidth, setBoxDimensions, setContainingBlock, setContainingLayer, setContentWidth, setHeight, setIndex, setLayer, setLeftMBP, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setParent, setPseudoElementOrClass, setRelativeOffset, setRightMBP, setState, setStyle, setTx, setTy, setX, setY, stateToString
-
-
-
-
Constructor Detail
-
AnonymousBlockBox
public AnonymousBlockBox(Element element)
-
-
Method Detail
-
layout
public void layout(LayoutContext c)
-
getContentWidth
public int getContentWidth()
- Overrides:
getContentWidthin classBox
-
find
public Box find(CssContext cssCtx, int absX, int absY, boolean findAnonymous)
-
isSkipWhenCollapsingMargins
public boolean isSkipWhenCollapsingMargins()
- Overrides:
isSkipWhenCollapsingMarginsin classBlockBox
-
provideSiblingMarginToFloats
public void provideSiblingMarginToFloats(int margin)
-
isMayCollapseMarginsWithChildren
public boolean isMayCollapseMarginsWithChildren()
- Overrides:
isMayCollapseMarginsWithChildrenin classBlockBox
-
styleText
public void styleText(LayoutContext c)
-
-