/** * Add this property to the CssStyle * * @param style The CssStyle */ public void addToStyle(ApplContext ac, CssStyle style) { if (top != null) { top.addToStyle(ac, style); } if (right != null) { right.addToStyle(ac, style); } if (left != null) { left.addToStyle(ac, style); } if (bottom != null) { bottom.addToStyle(ac, style); } }
/** Set this property to be important. Overrides this method for a macro */ public void setImportant() { if (top != null) { top.setImportant(); } if (right != null) { right.setImportant(); } if (left != null) { left.setImportant(); } if (bottom != null) { bottom.setImportant(); } }
/** * Update the source file and the line. Overrides this method for a macro * * @param line The line number where this property is defined * @param source The source file where this property is defined */ public void setInfo(int line, String source) { super.setInfo(line, source); if (top != null) { top.setInfo(line, source); } if (right != null) { right.setInfo(line, source); } if (left != null) { left.setInfo(line, source); } if (bottom != null) { bottom.setInfo(line, source); } }
/** * Set the context. Overrides this method for a macro * * @see org.w3c.css.css.CssCascadingOrder#order * @see org.w3c.css.css.StyleSheetParser#handleRule */ public void setSelectors(CssSelectors selector) { super.setSelectors(selector); if (top != null) { top.setSelectors(selector); } if (right != null) { right.setSelectors(selector); } if (bottom != null) { bottom.setSelectors(selector); } if (left != null) { left.setSelectors(selector); } }
/** Returns true if this property is important. Overrides this method for a macro */ public boolean getImportant() { return ((top == null || top.getImportant()) && (right == null || right.getImportant()) && (left == null || left.getImportant()) && (bottom == null || bottom.getImportant())); }