public void applyAreaContainerOffsets(AreaContainer ac, Area area) { int height = area.getAbsoluteHeight(); BlockArea ba = (BlockArea)area; foreach (LinkedRectangle r in rects) { r.setX(r.getX() + ac.getXPosition() + area.getTableCellXOffset()); r.setY(ac.GetYPosition() - height + (maxY - r.getY()) - ba.getHalfLeading()); } }
public bool needsFootnoteAdjusting() { footnoteYPosition = footnoteReferenceArea.GetYPosition(); switch (footnoteState) { case 0: resetHeights(); if (footnoteReferenceArea.GetHeight() > 0 && mainYPosition + mainReferenceArea.GetHeight() > footnoteYPosition) { return(true); } break; case 1: break; } return(false); }
public void RenderAreaContainer(AreaContainer area) { int saveY = this.currentYPosition; int saveX = this.currentAreaContainerXPosition; if (area.getPosition() == Position.ABSOLUTE) { // XPosition and YPosition give the content rectangle position this.currentYPosition = area.GetYPosition(); this.currentAreaContainerXPosition = area.getXPosition(); } else if (area.getPosition() == Position.RELATIVE) { this.currentYPosition -= area.GetYPosition(); this.currentAreaContainerXPosition += area.getXPosition(); } else if (area.getPosition() == Position.STATIC) { this.currentYPosition -= area.getPaddingTop() + area.getBorderTopWidth(); } this.currentXPosition = this.currentAreaContainerXPosition; DoFrame(area); foreach (Box b in area.getChildren()) { b.render(this); } // Restore previous origin this.currentYPosition = saveY; this.currentAreaContainerXPosition = saveX; if (area.getPosition() == Position.STATIC) { this.currentYPosition -= area.GetHeight(); } }