1 58 package org.apache.ecs.html; 59 60 import org.apache.ecs.*; 61 68 69 public class Caption extends MultiPartElement implements Printable, MouseEvents, KeyEvents 70 { 71 74 { 75 setElementType("caption"); 76 } 77 78 81 public Caption() 82 { 83 } 84 85 89 public Caption setAlign(String align) 90 { 91 addAttribute("align",align); 92 return(this); 93 } 94 95 100 public Caption addElement(String hashcode,Element element) 101 { 102 addElementToRegistry(hashcode,element); 103 return(this); 104 } 105 106 111 public Caption addElement(String hashcode,String element) 112 { 113 addElementToRegistry(hashcode,element); 114 return(this); 115 } 116 120 public Caption addElement(String element) 121 { 122 addElementToRegistry(Integer.toString(element.hashCode()),element); 123 return(this); 124 } 125 126 130 public Caption addElement(Element element) 131 { 132 addElementToRegistry(element); 133 return(this); 134 } 135 139 public Caption removeElement(String hashcode) 140 { 141 removeElementFromRegistry(hashcode); 142 return(this); 143 } 144 145 151 public void setOnClick(String script) 152 { 153 addAttribute ( "onClick", script ); 154 } 155 161 public void setOnDblClick(String script) 162 { 163 addAttribute ( "onDblClick", script ); 164 } 165 171 public void setOnMouseDown(String script) 172 { 173 addAttribute ( "onMouseDown", script ); 174 } 175 181 public void setOnMouseUp(String script) 182 { 183 addAttribute ( "onMouseUp", script ); 184 } 185 191 public void setOnMouseOver(String script) 192 { 193 addAttribute ( "onMouseOver", script ); 194 } 195 201 public void setOnMouseMove(String script) 202 { 203 addAttribute ( "onMouseMove", script ); 204 } 205 211 public void setOnMouseOut(String script) 212 { 213 addAttribute ( "onMouseOut", script ); 214 } 215 216 222 public void setOnKeyPress(String script) 223 { 224 addAttribute ( "onKeyPress", script ); 225 } 226 227 233 public void setOnKeyDown(String script) 234 { 235 addAttribute ( "onKeyDown", script ); 236 } 237 238 244 public void setOnKeyUp(String script) 245 { 246 addAttribute ( "onKeyUp", script ); 247 } 248 } 249 | Popular Tags |