1 58 package org.apache.ecs.html; 59 60 import org.apache.ecs.*; 61 62 69 public class H2 extends MultiPartElement implements Printable, MouseEvents, KeyEvents 70 { 71 74 { 75 setElementType("h2"); 76 } 77 78 82 public H2() 83 { 84 } 85 86 92 public H2(String value) 93 { 94 addElement(value); 95 } 96 100 105 public H2 addElement(String hashcode,Element element) 106 { 107 addElementToRegistry(hashcode,element); 108 return(this); 109 } 110 111 116 public H2 addElement(String hashcode,String element) 117 { 118 addElementToRegistry(hashcode,element); 119 return(this); 120 } 121 122 public H2 addElement(Element element) 123 { 124 addElementToRegistry(element); 125 return(this); 126 } 127 131 public H2 addElement(String element) 132 { 133 addElementToRegistry(element); 134 return(this); 135 } 136 140 public H2 removeElement(String hashcode) 141 { 142 removeElementFromRegistry(hashcode); 143 return(this); 144 } 145 146 152 public void setOnClick(String script) 153 { 154 addAttribute ( "onClick", script ); 155 } 156 162 public void setOnDblClick(String script) 163 { 164 addAttribute ( "onDblClick", script ); 165 } 166 172 public void setOnMouseDown(String script) 173 { 174 addAttribute ( "onMouseDown", script ); 175 } 176 182 public void setOnMouseUp(String script) 183 { 184 addAttribute ( "onMouseUp", script ); 185 } 186 192 public void setOnMouseOver(String script) 193 { 194 addAttribute ( "onMouseOver", script ); 195 } 196 202 public void setOnMouseMove(String script) 203 { 204 addAttribute ( "onMouseMove", script ); 205 } 206 212 public void setOnMouseOut(String script) 213 { 214 addAttribute ( "onMouseOut", script ); 215 } 216 217 223 public void setOnKeyPress(String script) 224 { 225 addAttribute ( "onKeyPress", script ); 226 } 227 228 234 public void setOnKeyDown(String script) 235 { 236 addAttribute ( "onKeyDown", script ); 237 } 238 239 245 public void setOnKeyUp(String script) 246 { 247 addAttribute ( "onKeyUp", script ); 248 } 249 } 250 | Popular Tags |