org.jfree.layouting.renderer.model
Class RenderBox
public abstract
class
RenderBox
extends RenderNode
A render-box corresponds to elements in a DOM tree.
Each box has a size, paddings, margins and borders. Boxes may have one or more childs.
While all nodes may have a position or dimensions, boxes are special, as they can have borders, margins and paddings.
Borders, paddings and margins can have percentages, the margins can additionally be 'auto'.
The StrictInset variables for these properties contain the resolved values, while the box-definition contain the
unresolved values. The resolve values are not valid unless the object has been validated to least least 'LAYOUTING'.
Author: Thomas Morgner
public static final boolean LOG_PRUNE
public void clear()
Removes all children.
public Object clone()
Clones this node. Be aware that cloning can get you into deep trouble, as the relations this node has may no longer
be valid.
Returns:
public void close()
Derive creates a disconnected node that shares all the properties of the original node. The derived node will no
longer have any parent, silbling, child or any other relationships with other nodes.
Returns:
public
RenderNode deriveFrozen(boolean deepDerive)
Derive creates a disconnected node that shares all the properties of the original node. The derived node will no
longer have any parent, silbling, child or any other relationships with other nodes.
Returns:
public void freeze()
public long getContentAreaX1()
public long getContentAreaX2()
public long getEffectiveMarginBottom()
public long getEffectiveMarginTop()
public int getLineCount()
public int getOrphans()
public long getOrphansSize()
public int getWidows()
public long getWidowsSize()
Derive creates a disconnected node that shares all the properties of the original node. The derived node will no
longer have any parent, silbling, child or any other relationships with other nodes.
Returns:
Inserts the given target after the specified node. If the node is null, the target is inserted as first node.
Parameters: node target
Inserts the given target directly before the the specified node. If the node is null, the element is inserted at
the last position.
Parameters: node target
public boolean isAppendable()
public boolean isAvoidPagebreakInside()
public boolean isDiscardable()
public boolean isEmpty()
public boolean isOpen()
public boolean isPreserveSpace()
public void setContentAreaX1(long contentAreaX1)
public void setContentAreaX2(long contentAreaX2)
protected void setFirstChild(
RenderNode firstChild)
public void setLineCount(int lineCount)
public void setOrphansSize(long orphansSize)
public void setWidowsSize(long widowsSize)
Performs a simple split. This box will be altered to form the left/top side of the split, and a derived empty box
will be returned, which makes up the right/bottom side.
A split will only happen on inline-boxes during the line-break-step. In the ordinary layouting, splitting is not
necesary.
Parameters: axis
Returns: