1 58 package org.apache.ecs.xhtml; 59 60 import org.apache.ecs.*; 61 62 69 public class basefont extends SinglePartElement implements Printable 70 { 71 72 75 { 76 setElementType("basefont"); 77 setCase(LOWERCASE); 78 setAttributeQuote(true); 79 setBeginEndModifier('/'); 80 } 81 82 85 public basefont() 86 { 87 } 88 89 93 public basefont(String face) 94 { 95 setFace(face); 96 } 97 98 104 public basefont(String face,String color) 105 { 106 setFace(face); 107 setColor(color); 108 } 109 110 117 public basefont(String face,String color,int size) 118 { 119 setFace(face); 120 setColor(color); 121 setSize(size); 122 } 123 124 129 public basefont(int size,String face) 130 { 131 setSize(size); 132 setFace(face); 133 } 134 135 141 public basefont(String color,int size) 142 { 143 setSize(size); 144 setColor(color); 145 } 146 147 151 public basefont setFace(String face) 152 { 153 addAttribute("face",face); 154 return(this); 155 } 156 157 161 public basefont setColor(String color) 162 { 163 addAttribute("color",HtmlColor.convertColor(color)); 164 return(this); 165 } 166 167 171 public basefont setSize(int size) 172 { 173 addAttribute("size",Integer.toString(size)); 174 return(this); 175 } 176 177 181 public basefont setSize(String size) 182 { 183 addAttribute("size",size); 184 return(this); 185 } 186 187 191 public Element setLang(String lang) 192 { 193 addAttribute("lang",lang); 194 addAttribute("xml:lang",lang); 195 return this; 196 } 197 198 203 public basefont addElement(String hashcode,Element element) 204 { 205 addElementToRegistry(hashcode,element); 206 return(this); 207 } 208 209 214 public basefont addElement(String hashcode,String element) 215 { 216 addElementToRegistry(hashcode,element); 217 return(this); 218 } 219 220 224 public basefont addElement(Element element) 225 { 226 addElementToRegistry(element); 227 return(this); 228 } 229 230 234 public basefont addElement(String element) 235 { 236 addElementToRegistry(element); 237 return(this); 238 } 239 243 public basefont removeElement(String hashcode) 244 { 245 removeElementFromRegistry(hashcode); 246 return(this); 247 } 248 } 249 | Popular Tags |