1 17 18 19 20 package org.apache.fop.area; 21 22 import java.util.ArrayList ; 23 import java.util.List ; 24 25 28 public class BlockParent extends Area { 29 30 34 39 protected int xOffset = 0; 40 41 46 protected int yOffset = 0; 47 48 51 protected List children = null; 52 53 private int orientation = ORIENT_0; 55 56 57 public void addChildArea(Area childArea) { 58 if (children == null) { 59 children = new ArrayList (); 60 } 61 children.add(childArea); 62 } 63 64 69 public void addBlock(Block block) { 70 addChildArea(block); 71 } 72 73 78 public List getChildAreas() { 79 return children; 80 } 81 82 87 public boolean isEmpty() { 88 return children == null || children.size() == 0; 89 } 90 91 96 public void setXOffset(int off) { 97 xOffset = off; 98 } 99 100 105 public void setYOffset(int off) { 106 yOffset = off; 107 } 108 109 114 public int getXOffset() { 115 return xOffset; 116 } 117 118 123 public int getYOffset() { 124 return yOffset; 125 } 126 } 127 | Popular Tags |