public void calcChildLocations() { for (int i = 0; i < getInlineChildCount(); i++) { Object obj = getInlineChild(i); if (obj instanceof Box) { Box child = (Box)obj; child.calcCanvasLocation(); child.calcChildLocations(); } } }
public void calcChildLocations() { for (int i = 0; i < getChildCount(); i++) { Box child = getChild(i); child.calcCanvasLocation(); child.calcChildLocations(); } }
public void calcChildLocations() { for (int i = 0; i < getInlineChildCount(); i++) { Object obj = getInlineChild(i); if (obj instanceof Box) { Box child = (Box)obj; child.calcCanvasLocation(); child.calcChildLocations(); } } }
public void calcChildLocations() { for (int i = 0; i < getChildCount(); i++) { Box child = getChild(i); child.calcCanvasLocation(); child.calcChildLocations(); } }
public void calcChildLocations() { super.calcChildLocations(); // Update absolute boxes too. Not necessary most of the time, but // it doesn't hurt (revisit this) for (int i = 0; i < getNonFlowContent().size(); i++) { Box content = (Box)getNonFlowContent().get(i); if (content.getStyle().isAbsolute()) { content.calcCanvasLocation(); content.calcChildLocations(); } } }
public void calcChildLocations() { super.calcChildLocations(); // Update absolute boxes too. Not necessary most of the time, but // it doesn't hurt (revisit this) for (int i = 0; i < getNonFlowContent().size(); i++) { Box content = (Box)getNonFlowContent().get(i); if (content.getStyle().isAbsolute()) { content.calcCanvasLocation(); content.calcChildLocations(); } } }
public Dimension positionRelative(CssContext cssCtx) { Dimension delta = super.positionRelative(cssCtx); setX(getX() - delta.width); setY(getY() - delta.height); List toTranslate = getElementWithContent(); for (int i = 0; i < toTranslate.size(); i++) { Box b = (Box)toTranslate.get(i); b.setX(b.getX() + delta.width); b.setY(b.getY() + delta.height); b.calcCanvasLocation(); b.calcChildLocations(); } return delta; }
public Dimension positionRelative(CssContext cssCtx) { Dimension delta = super.positionRelative(cssCtx); setX(getX() - delta.width); setY(getY() - delta.height); List toTranslate = getElementWithContent(); for (int i = 0; i < toTranslate.size(); i++) { Box b = (Box)toTranslate.get(i); b.setX(b.getX() + delta.width); b.setY(b.getY() + delta.height); b.calcCanvasLocation(); b.calcChildLocations(); } return delta; }
if (getMaster().getStyle().isAbsolute() && ! c.isPrint()) { ((BlockBox)getMaster()).positionAbsolute(c, BlockBox.POSITION_BOTH); } else if (getMaster().getStyle().isRelative() && (isInline() || ((BlockBox)getMaster()).isInline())) { getMaster().positionRelative(c); if (! isInline()) { getMaster().calcCanvasLocation(); getMaster().calcChildLocations(); } } } private boolean containsFixedLayer() {
private void position(LayoutContext c) { if (getMaster().getStyle().isAbsolute() && ! c.isPrint()) { ((BlockBox)getMaster()).positionAbsolute(c, BlockBox.POSITION_BOTH); } else if (getMaster().getStyle().isRelative() && (isInline() || ((BlockBox)getMaster()).isInline())) { getMaster().positionRelative(c); if (! isInline()) { getMaster().calcCanvasLocation(); getMaster().calcChildLocations(); } } }