public TextLayout add(Css css) { TextLayout newL = clone(); for (P p : css.getProperties()) { newL.getProperties().add(p); } return newL; }
@SuppressWarnings({"CloneDoesntDeclareCloneNotSupportedException", "CloneDoesntCallSuperClone"}) public TextLayout clone() { TextLayout l = new TextLayout(topMargin, rightMargin, bottomMargin, leftMargin); l.setHeight(height); l.setWidth(width); l.setAlignH(alignH); l.setAlignV(alignV); for (P p : properties) { l.getProperties().add(p); } return l; }
public TextLayout add(Name name, String value) { TextLayout newL = clone(); newL.getProperties().add(new P(name, value)); return newL; }
public TextLayout add(P p) { TextLayout newL = clone(); newL.getProperties().add(p); return newL; }