# khtml Library API Documentation

Overview | Class Hierarchy | Classes | Classes (annotated) | Members | Source Files

# html_base.cpp

    00001
    00021 // --------------------------------------------------------------------------
    00022
    00023 #include "dom/dom_doc.h"
    00024 #include "dom/html_base.h"
    00025 #include "html/html_baseimpl.h"
    00026 #include "misc/htmlhashes.h"
    00027
    00028 using namespace DOM;
    00029
    00030 HTMLBodyElement::HTMLBodyElement() : HTMLElement()
    00031 {
    00032 }
    00033
    00034 HTMLBodyElement::HTMLBodyElement(const HTMLBodyElement &other) : HTMLElement(other)
    00035 {
    00036 }
    00037
    00038 HTMLBodyElement::HTMLBodyElement(HTMLBodyElementImpl *impl) : HTMLElement(impl)
    00039 {
    00040 }
    00041
    00042 HTMLBodyElement &HTMLBodyElement::operator = (const Node &other)
    00043 {
    00044     assignOther( other, ID_BODY );
    00045     return *this;
    00046 }
    00047
    00048 HTMLBodyElement &HTMLBodyElement::operator = (const HTMLBodyElement &other)
    00049 {
    00050     HTMLElement::operator = (other);
    00051     return *this;
    00052 }
    00053
    00054 HTMLBodyElement::~HTMLBodyElement()
    00055 {
    00056 }
    00057
    00058 DOMString HTMLBodyElement::aLink() const
    00059 {
    00060     return impl ? ((ElementImpl *)impl)->getAttribute(ATTR_ALINK) : DOMString();
    00061 }
    00062
    00063 void HTMLBodyElement::setALink( const DOMString &value )
    00064 {
    00065     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALINK, value);
    00066 }
    00067
    00068 DOMString HTMLBodyElement::background() const
    00069 {
    00070     return impl ? ((ElementImpl *)impl)->getAttribute(ATTR_BACKGROUND) : DOMString();
    00071 }
    00072
    00073 void HTMLBodyElement::setBackground( const DOMString &value )
    00074 {
    00075     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BACKGROUND, value);
    00076 }
    00077
    00078 DOMString HTMLBodyElement::bgColor() const
    00079 {
    00080     if(!impl) return DOMString();
    00081     return ((ElementImpl *)impl)->getAttribute(ATTR_BGCOLOR);
    00082 }
    00083
    00084 void HTMLBodyElement::setBgColor( const DOMString &value )
    00085 {
    00086     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BGCOLOR, value);
    00087 }
    00088
    00089 DOMString HTMLBodyElement::link() const
    00090 {
    00091     if(!impl) return DOMString();
    00092     return ((ElementImpl *)impl)->getAttribute(ATTR_LINK);
    00093 }
    00094
    00095 void HTMLBodyElement::setLink( const DOMString &value )
    00096 {
    00097     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_LINK, value);
    00098 }
    00099
    00100 DOMString HTMLBodyElement::text() const
    00101 {
    00102     if(!impl) return DOMString();
    00103     return ((ElementImpl *)impl)->getAttribute(ATTR_TEXT);
    00104 }
    00105
    00106 void HTMLBodyElement::setText( const DOMString &value )
    00107 {
    00108     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TEXT, value);
    00109 }
    00110
    00111 DOMString HTMLBodyElement::vLink() const
    00112 {
    00113     if(!impl) return DOMString();
    00114     return ((ElementImpl *)impl)->getAttribute(ATTR_VLINK);
    00115 }
    00116
    00117 void HTMLBodyElement::setVLink( const DOMString &value )
    00118 {
    00119     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VLINK, value);
    00120 }
    00121
    00122 // --------------------------------------------------------------------------
    00123
    00124 HTMLFrameElement::HTMLFrameElement() : HTMLElement()
    00125 {
    00126 }
    00127
    00128 HTMLFrameElement::HTMLFrameElement(const HTMLFrameElement &other) : HTMLElement(other)
    00129 {
    00130 }
    00131
    00132 HTMLFrameElement::HTMLFrameElement(HTMLFrameElementImpl *impl) : HTMLElement(impl)
    00133 {
    00134 }
    00135
    00136 HTMLFrameElement &HTMLFrameElement::operator = (const Node &other)
    00137 {
    00138     assignOther( other, ID_FRAME );
    00139     return *this;
    00140 }
    00141
    00142 HTMLFrameElement &HTMLFrameElement::operator = (const HTMLFrameElement &other)
    00143 {
    00144     HTMLElement::operator = (other);
    00145     return *this;
    00146 }
    00147
    00148 HTMLFrameElement::~HTMLFrameElement()
    00149 {
    00150 }
    00151
    00152 DOMString HTMLFrameElement::frameBorder() const
    00153 {
    00154     if(!impl) return DOMString();
    00155     return ((ElementImpl *)impl)->getAttribute(ATTR_FRAMEBORDER);
    00156 }
    00157
    00158 void HTMLFrameElement::setFrameBorder( const DOMString &value )
    00159 {
    00160     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_FRAMEBORDER, value);
    00161 }
    00162
    00163 DOMString HTMLFrameElement::longDesc() const
    00164 {
    00165     if(!impl) return DOMString();
    00166     return ((ElementImpl *)impl)->getAttribute(ATTR_LONGDESC);
    00167 }
    00168
    00169 void HTMLFrameElement::setLongDesc( const DOMString &value )
    00170 {
    00171     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_LONGDESC, value);
    00172 }
    00173
    00174 DOMString HTMLFrameElement::marginHeight() const
    00175 {
    00176     if(!impl) return DOMString();
    00177     return ((ElementImpl *)impl)->getAttribute(ATTR_MARGINHEIGHT);
    00178 }
    00179
    00180 void HTMLFrameElement::setMarginHeight( const DOMString &value )
    00181 {
    00182     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_MARGINHEIGHT, value);
    00183 }
    00184
    00185 DOMString HTMLFrameElement::marginWidth() const
    00186 {
    00187     if(!impl) return DOMString();
    00188     return ((ElementImpl *)impl)->getAttribute(ATTR_MARGINWIDTH);
    00189 }
    00190
    00191 void HTMLFrameElement::setMarginWidth( const DOMString &value )
    00192 {
    00193     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_MARGINWIDTH, value);
    00194 }
    00195
    00196 DOMString HTMLFrameElement::name() const
    00197 {
    00198     if(!impl) return DOMString();
    00199     return ((ElementImpl *)impl)->getAttribute(ATTR_NAME);
    00200 }
    00201
    00202 void HTMLFrameElement::setName( const DOMString &value )
    00203 {
    00204     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_NAME, value);
    00205 }
    00206
    00207 bool HTMLFrameElement::noResize() const
    00208 {
    00209     if(!impl) return false;
    00210     return !((ElementImpl *)impl)->getAttribute(ATTR_NORESIZE).isNull();
    00211 }
    00212
    00213 void HTMLFrameElement::setNoResize( bool _noResize )
    00214 {
    00215     if(impl)
    00216     {
    00217         DOMString str;
    00218         if( _noResize )
    00219             str = "";
    00220         ((ElementImpl *)impl)->setAttribute(ATTR_NORESIZE, str);
    00221     }
    00222 }
    00223
    00224 DOMString HTMLFrameElement::scrolling() const
    00225 {
    00226     if(!impl) return DOMString();
    00227     return ((ElementImpl *)impl)->getAttribute(ATTR_SCROLLING);
    00228 }
    00229
    00230 void HTMLFrameElement::setScrolling( const DOMString &value )
    00231 {
    00232     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SCROLLING, value);
    00233 }
    00234
    00235 DOMString HTMLFrameElement::src() const
    00236 {
    00237     if(!impl) return DOMString();
    00238     return ((ElementImpl *)impl)->getAttribute(ATTR_SRC);
    00239 }
    00240
    00241 void HTMLFrameElement::setSrc( const DOMString &value )
    00242 {
    00243     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SRC, value);
    00244 }
    00245
    00246 Document HTMLFrameElement::contentDocument() const
    00247 {
    00248     if (impl) return static_cast<HTMLFrameElementImpl*>(impl)->contentDocument();
    00249     return Document();
    00250 }
    00251
    00252 // --------------------------------------------------------------------------
    00253
    00254 HTMLIFrameElement::HTMLIFrameElement() : HTMLElement()
    00255 {
    00256 }
    00257
    00258 HTMLIFrameElement::HTMLIFrameElement(const HTMLIFrameElement &other) : HTMLElement(other)
    00259 {
    00260 }
    00261
    00262 HTMLIFrameElement::HTMLIFrameElement(HTMLIFrameElementImpl *impl) : HTMLElement(impl)
    00263 {
    00264 }
    00265
    00266 HTMLIFrameElement &HTMLIFrameElement::operator = (const Node &other)
    00267 {
    00268     assignOther( other, ID_IFRAME );
    00269     return *this;
    00270 }
    00271
    00272 HTMLIFrameElement &HTMLIFrameElement::operator = (const HTMLIFrameElement &other)
    00273 {
    00274     HTMLElement::operator = (other);
    00275     return *this;
    00276 }
    00277
    00278 HTMLIFrameElement::~HTMLIFrameElement()
    00279 {
    00280 }
    00281
    00282 DOMString HTMLIFrameElement::align() const
    00283 {
    00284     if(!impl) return DOMString();
    00285     return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
    00286 }
    00287
    00288 void HTMLIFrameElement::setAlign( const DOMString &value )
    00289 {
    00290     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
    00291 }
    00292
    00293 DOMString HTMLIFrameElement::frameBorder() const
    00294 {
    00295     if(!impl) return DOMString();
    00296     return ((ElementImpl *)impl)->getAttribute(ATTR_FRAMEBORDER);
    00297 }
    00298
    00299 void HTMLIFrameElement::setFrameBorder( const DOMString &value )
    00300 {
    00301     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_FRAMEBORDER, value);
    00302 }
    00303
    00304 DOMString HTMLIFrameElement::height() const
    00305 {
    00306     if(!impl) return DOMString();
    00307     return ((ElementImpl *)impl)->getAttribute(ATTR_HEIGHT);
    00308 }
    00309
    00310 void HTMLIFrameElement::setHeight( const DOMString &value )
    00311 {
    00312     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HEIGHT, value);
    00313 }
    00314
    00315 DOMString HTMLIFrameElement::longDesc() const
    00316 {
    00317     if(!impl) return DOMString();
    00318     return ((ElementImpl *)impl)->getAttribute(ATTR_LONGDESC);
    00319 }
    00320
    00321 void HTMLIFrameElement::setLongDesc( const DOMString &value )
    00322 {
    00323     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_LONGDESC, value);
    00324 }
    00325
    00326 DOMString HTMLIFrameElement::marginHeight() const
    00327 {
    00328     if(!impl) return DOMString();
    00329     return ((ElementImpl *)impl)->getAttribute(ATTR_MARGINHEIGHT);
    00330 }
    00331
    00332 void HTMLIFrameElement::setMarginHeight( const DOMString &value )
    00333 {
    00334     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_MARGINHEIGHT, value);
    00335 }
    00336
    00337 DOMString HTMLIFrameElement::marginWidth() const
    00338 {
    00339     if(!impl) return DOMString();
    00340     return ((ElementImpl *)impl)->getAttribute(ATTR_MARGINWIDTH);
    00341 }
    00342
    00343 void HTMLIFrameElement::setMarginWidth( const DOMString &value )
    00344 {
    00345     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_MARGINWIDTH, value);
    00346 }
    00347
    00348 DOMString HTMLIFrameElement::name() const
    00349 {
    00350     if(!impl) return DOMString();
    00351     return ((ElementImpl *)impl)->getAttribute(ATTR_NAME);
    00352 }
    00353
    00354 void HTMLIFrameElement::setName( const DOMString &value )
    00355 {
    00356     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_NAME, value);
    00357 }
    00358
    00359 DOMString HTMLIFrameElement::scrolling() const
    00360 {
    00361     if(!impl) return DOMString();
    00362     return ((ElementImpl *)impl)->getAttribute(ATTR_SCROLLING);
    00363 }
    00364
    00365 void HTMLIFrameElement::setScrolling( const DOMString &value )
    00366 {
    00367     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SCROLLING, value);
    00368 }
    00369
    00370 DOMString HTMLIFrameElement::src() const
    00371 {
    00372     if(!impl) return DOMString();
    00373     return ((ElementImpl *)impl)->getAttribute(ATTR_SRC);
    00374 }
    00375
    00376 void HTMLIFrameElement::setSrc( const DOMString &value )
    00377 {
    00378     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SRC, value);
    00379 }
    00380
    00381 DOMString HTMLIFrameElement::width() const
    00382 {
    00383     if(!impl) return DOMString();
    00384     return ((ElementImpl *)impl)->getAttribute(ATTR_WIDTH);
    00385 }
    00386
    00387 void HTMLIFrameElement::setWidth( const DOMString &value )
    00388 {
    00389     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_WIDTH, value);
    00390 }
    00391
    00392 Document HTMLIFrameElement::contentDocument() const
    00393 {
    00394     if (impl) return static_cast<HTMLIFrameElementImpl*>(impl)->contentDocument();
    00395     return Document();
    00396 }
    00397
    00398 // --------------------------------------------------------------------------
    00399
    00400 HTMLFrameSetElement::HTMLFrameSetElement() : HTMLElement()
    00401 {
    00402 }
    00403
    00404 HTMLFrameSetElement::HTMLFrameSetElement(const HTMLFrameSetElement &other) : HTMLElement(other)
    00405 {
    00406 }
    00407
    00408 HTMLFrameSetElement::HTMLFrameSetElement(HTMLFrameSetElementImpl *impl) : HTMLElement(impl)
    00409 {
    00410 }
    00411
    00412 HTMLFrameSetElement &HTMLFrameSetElement::operator = (const Node &other)
    00413 {
    00414     assignOther( other, ID_FRAMESET );
    00415     return *this;
    00416 }
    00417
    00418 HTMLFrameSetElement &HTMLFrameSetElement::operator = (const HTMLFrameSetElement &other)
    00419 {
    00420     HTMLElement::operator = (other);
    00421     return *this;
    00422 }
    00423
    00424 HTMLFrameSetElement::~HTMLFrameSetElement()
    00425 {
    00426 }
    00427
    00428 DOMString HTMLFrameSetElement::cols() const
    00429 {
    00430     if(!impl) return DOMString();
    00431     return ((ElementImpl *)impl)->getAttribute(ATTR_COLS);
    00432 }
    00433
    00434 void HTMLFrameSetElement::setCols( const DOMString &value )
    00435 {
    00436     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_COLS, value);
    00437 }
    00438
    00439 DOMString HTMLFrameSetElement::rows() const
    00440 {
    00441     if(!impl) return DOMString();
    00442     return ((ElementImpl *)impl)->getAttribute(ATTR_ROWS);
    00443 }
    00444
    00445 void HTMLFrameSetElement::setRows( const DOMString &value )
    00446 {
    00447     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ROWS, value);
    00448 }
    00449
    00450 // --------------------------------------------------------------------------
    00451
    00452 HTMLHeadElement::HTMLHeadElement() : HTMLElement()
    00453 {
    00454 }
    00455
    00456 HTMLHeadElement::HTMLHeadElement(const HTMLHeadElement &other) : HTMLElement(other)
    00457 {
    00458 }
    00459
    00460 HTMLHeadElement::HTMLHeadElement(HTMLHeadElementImpl *impl) : HTMLElement(impl)
    00461 {
    00462 }
    00463
    00464 HTMLHeadElement &HTMLHeadElement::operator = (const Node &other)
    00465 {
    00466     assignOther( other, ID_HEAD );
    00467     return *this;
    00468 }
    00469
    00470 HTMLHeadElement &HTMLHeadElement::operator = (const HTMLHeadElement &other)
    00471 {
    00472     HTMLElement::operator = (other);
    00473     return *this;
    00474 }
    00475
    00476 HTMLHeadElement::~HTMLHeadElement()
    00477 {
    00478 }
    00479
    00480 DOMString HTMLHeadElement::profile() const
    00481 {
    00482     if(!impl) return DOMString();
    00483     return ((ElementImpl *)impl)->getAttribute(ATTR_PROFILE);
    00484 }
    00485
    00486 void HTMLHeadElement::setProfile( const DOMString &value )
    00487 {
    00488     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_PROFILE, value);
    00489 }
    00490
    00491 // --------------------------------------------------------------------------
    00492
    00493 HTMLHtmlElement::HTMLHtmlElement() : HTMLElement()
    00494 {
    00495 }
    00496
    00497 HTMLHtmlElement::HTMLHtmlElement(const HTMLHtmlElement &other) : HTMLElement(other)
    00498 {
    00499 }
    00500
    00501 HTMLHtmlElement::HTMLHtmlElement(HTMLHtmlElementImpl *impl) : HTMLElement(impl)
    00502 {
    00503 }
    00504
    00505 HTMLHtmlElement &HTMLHtmlElement::operator = (const Node &other)
    00506 {
    00507     assignOther( other, ID_HTML );
    00508     return *this;
    00509 }
    00510
    00511 HTMLHtmlElement &HTMLHtmlElement::operator = (const HTMLHtmlElement &other)
    00512 {
    00513     HTMLElement::operator = (other);
    00514     return *this;
    00515 }
    00516
    00517 HTMLHtmlElement::~HTMLHtmlElement()
    00518 {
    00519 }
    00520
    00521 DOMString HTMLHtmlElement::version() const
    00522 {
    00523     if(!impl) return DOMString();
    00524     return ((ElementImpl *)impl)->getAttribute(ATTR_VERSION);
    00525 }
    00526
    00527 void HTMLHtmlElement::setVersion( const DOMString &value )
    00528 {
    00529     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VERSION, value);
    00530 }
    00531

This file is part of the documentation for kdelibs Version 3.1.5.
Documentation copyright © 1996-2002 the KDE developers.
Generated on Wed Jan 28 13:33:49 2004 by doxygen 1.3.4 written by Dimitri van Heesch, © 1997-2001