1 13 package info.magnolia.cms.gui.misc; 14 15 20 public final class Spacer { 21 22 25 private Spacer() { 26 } 27 28 34 public static String getHtml(int height, int width) { 35 36 StringBuffer buffer = new StringBuffer (120); 37 buffer.append("<div class=\""); buffer.append(CssConstants.CSSCLASS_TINYVSPACE); 39 buffer.append("\" "); 41 if (height != 0 || width != 0) { 42 buffer.append("style=\""); if (height != 0) { 44 buffer.append("height:" + height + "px;"); } 46 if (width != 0) { 47 buffer.append("width:" + width + "px;"); } 49 buffer.append("\" "); } 51 52 buffer.append("><!-- ie --></div>"); 54 return buffer.toString(); 55 } 56 } 57 | Popular Tags |