• Skip to content
  • Skip to link menu
KDE 4.6 API Reference
  • KDE API Reference
  • kdelibs
  • KDE Home
  • Contact Us
 

KHTML

html_head.cpp

Go to the documentation of this file.
00001 
00022 // --------------------------------------------------------------------------
00023 
00024 #include "dom/html_head.h"
00025 #include "html/html_headimpl.h"
00026 #include "xml/dom_docimpl.h"
00027 
00028 using namespace DOM;
00029 
00030 HTMLBaseElement::HTMLBaseElement() : HTMLElement()
00031 {
00032 }
00033 
00034 HTMLBaseElement::HTMLBaseElement(const HTMLBaseElement &other) : HTMLElement(other)
00035 {
00036 }
00037 
00038 HTMLBaseElement::HTMLBaseElement(HTMLBaseElementImpl *impl) : HTMLElement(impl)
00039 {
00040 }
00041 
00042 HTMLBaseElement &HTMLBaseElement::operator = (const Node &other)
00043 {
00044     assignOther( other, ID_BASE );
00045     return *this;
00046 }
00047 
00048 HTMLBaseElement &HTMLBaseElement::operator = (const HTMLBaseElement &other)
00049 {
00050     HTMLElement::operator = (other);
00051     return *this;
00052 }
00053 
00054 HTMLBaseElement::~HTMLBaseElement()
00055 {
00056 }
00057 
00058 DOMString HTMLBaseElement::href() const
00059 {
00060     if(!impl) return DOMString();
00061     DOMString href = static_cast<ElementImpl*>(impl)->getAttribute(ATTR_HREF);
00062     return !href.isNull() ? impl->document()->completeURL(href.string()) : href;
00063 }
00064 
00065 void HTMLBaseElement::setHref( const DOMString &value )
00066 {
00067     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HREF, value);
00068 }
00069 
00070 DOMString HTMLBaseElement::target() const
00071 {
00072     if(!impl) return DOMString();
00073     return ((ElementImpl *)impl)->getAttribute(ATTR_TARGET);
00074 }
00075 
00076 void HTMLBaseElement::setTarget( const DOMString &value )
00077 {
00078     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TARGET, value);
00079 }
00080 
00081 // --------------------------------------------------------------------------
00082 
00083 HTMLLinkElement::HTMLLinkElement() : HTMLElement()
00084 {
00085 }
00086 
00087 HTMLLinkElement::HTMLLinkElement(const HTMLLinkElement &other) : HTMLElement(other)
00088 {
00089 }
00090 
00091 HTMLLinkElement::HTMLLinkElement(HTMLLinkElementImpl *impl) : HTMLElement(impl)
00092 {
00093 }
00094 
00095 HTMLLinkElement &HTMLLinkElement::operator = (const Node &other)
00096 {
00097     assignOther( other, ID_LINK );
00098     return *this;
00099 }
00100 
00101 HTMLLinkElement &HTMLLinkElement::operator = (const HTMLLinkElement &other)
00102 {
00103     HTMLElement::operator = (other);
00104     return *this;
00105 }
00106 
00107 HTMLLinkElement::~HTMLLinkElement()
00108 {
00109 }
00110 
00111 bool HTMLLinkElement::disabled() const
00112 {
00113     if(!impl) return 0;
00114     return !((ElementImpl *)impl)->getAttribute(ATTR_DISABLED).isNull();
00115 }
00116 
00117 void HTMLLinkElement::setDisabled( bool _disabled )
00118 {
00119     if(impl)
00120         ((ElementImpl *)impl)->setAttribute(ATTR_DISABLED, _disabled ? "" : 0);
00121 }
00122 
00123 DOMString HTMLLinkElement::charset() const
00124 {
00125     if(!impl) return DOMString();
00126     return ((ElementImpl *)impl)->getAttribute(ATTR_CHARSET);
00127 }
00128 
00129 void HTMLLinkElement::setCharset( const DOMString &value )
00130 {
00131     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHARSET, value);
00132 }
00133 
00134 DOMString HTMLLinkElement::href() const
00135 {
00136     if(!impl) return DOMString();
00137     DOMString href = static_cast<ElementImpl*>(impl)->getAttribute(ATTR_HREF);
00138     return !href.isNull() ? impl->document()->completeURL(href.string()) : href;
00139 }
00140 
00141 void HTMLLinkElement::setHref( const DOMString &value )
00142 {
00143     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HREF, value);
00144 }
00145 
00146 DOMString HTMLLinkElement::hreflang() const
00147 {
00148     if(!impl) return DOMString();
00149     return ((ElementImpl *)impl)->getAttribute(ATTR_HREFLANG);
00150 }
00151 
00152 void HTMLLinkElement::setHreflang( const DOMString &value )
00153 {
00154     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HREFLANG, value);
00155 }
00156 
00157 DOMString HTMLLinkElement::media() const
00158 {
00159     if(!impl) return DOMString();
00160     return ((ElementImpl *)impl)->getAttribute(ATTR_MEDIA);
00161 }
00162 
00163 void HTMLLinkElement::setMedia( const DOMString &value )
00164 {
00165     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_MEDIA, value);
00166 }
00167 
00168 DOMString HTMLLinkElement::rel() const
00169 {
00170     if(!impl) return DOMString();
00171     return ((ElementImpl *)impl)->getAttribute(ATTR_REL);
00172 }
00173 
00174 void HTMLLinkElement::setRel( const DOMString &value )
00175 {
00176     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_REL, value);
00177 }
00178 
00179 DOMString HTMLLinkElement::rev() const
00180 {
00181     if(!impl) return DOMString();
00182     return ((ElementImpl *)impl)->getAttribute(ATTR_REV);
00183 }
00184 
00185 void HTMLLinkElement::setRev( const DOMString &value )
00186 {
00187     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_REV, value);
00188 }
00189 
00190 DOMString HTMLLinkElement::target() const
00191 {
00192     if(!impl) return DOMString();
00193     return ((ElementImpl *)impl)->getAttribute(ATTR_TARGET);
00194 }
00195 
00196 void HTMLLinkElement::setTarget( const DOMString &value )
00197 {
00198     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TARGET, value);
00199 }
00200 
00201 DOMString HTMLLinkElement::type() const
00202 {
00203     if(!impl) return DOMString();
00204     return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
00205 }
00206 
00207 void HTMLLinkElement::setType( const DOMString &value )
00208 {
00209     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
00210 }
00211 
00212 StyleSheet HTMLLinkElement::sheet() const
00213 {
00214     if(!impl) return 0;
00215     return ((HTMLLinkElementImpl *)impl)->sheet();
00216 }
00217 
00218 // --------------------------------------------------------------------------
00219 
00220 HTMLMetaElement::HTMLMetaElement() : HTMLElement()
00221 {
00222 }
00223 
00224 HTMLMetaElement::HTMLMetaElement(const HTMLMetaElement &other) : HTMLElement(other)
00225 {
00226 }
00227 
00228 HTMLMetaElement::HTMLMetaElement(HTMLMetaElementImpl *impl) : HTMLElement(impl)
00229 {
00230 }
00231 
00232 HTMLMetaElement &HTMLMetaElement::operator = (const Node &other)
00233 {
00234     assignOther( other, ID_META );
00235     return *this;
00236 }
00237 
00238 HTMLMetaElement &HTMLMetaElement::operator = (const HTMLMetaElement &other)
00239 {
00240     HTMLElement::operator = (other);
00241     return *this;
00242 }
00243 
00244 HTMLMetaElement::~HTMLMetaElement()
00245 {
00246 }
00247 
00248 DOMString HTMLMetaElement::content() const
00249 {
00250     if(!impl) return DOMString();
00251     return ((ElementImpl *)impl)->getAttribute(ATTR_CONTENT);
00252 }
00253 
00254 void HTMLMetaElement::setContent( const DOMString &value )
00255 {
00256     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CONTENT, value);
00257 }
00258 
00259 DOMString HTMLMetaElement::httpEquiv() const
00260 {
00261     if(!impl) return DOMString();
00262     return ((ElementImpl *)impl)->getAttribute(ATTR_HTTP_EQUIV);
00263 }
00264 
00265 void HTMLMetaElement::setHttpEquiv( const DOMString &value )
00266 {
00267     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HTTP_EQUIV, value);
00268 }
00269 
00270 DOMString HTMLMetaElement::name() const
00271 {
00272     if(!impl) return DOMString();
00273     return ((ElementImpl *)impl)->getAttribute(ATTR_NAME);
00274 }
00275 
00276 void HTMLMetaElement::setName( const DOMString &value )
00277 {
00278     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_NAME, value);
00279 }
00280 
00281 DOMString HTMLMetaElement::scheme() const
00282 {
00283     if(!impl) return DOMString();
00284     return ((ElementImpl *)impl)->getAttribute(ATTR_SCHEME);
00285 }
00286 
00287 void HTMLMetaElement::setScheme( const DOMString &value )
00288 {
00289     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SCHEME, value);
00290 }
00291 
00292 // --------------------------------------------------------------------------
00293 
00294 HTMLScriptElement::HTMLScriptElement() : HTMLElement()
00295 {
00296 }
00297 
00298 HTMLScriptElement::HTMLScriptElement(const HTMLScriptElement &other) : HTMLElement(other)
00299 {
00300 }
00301 
00302 HTMLScriptElement::HTMLScriptElement(HTMLScriptElementImpl *impl) : HTMLElement(impl)
00303 {
00304 }
00305 
00306 HTMLScriptElement &HTMLScriptElement::operator = (const Node &other)
00307 {
00308     assignOther( other, ID_SCRIPT );
00309     return *this;
00310 }
00311 
00312 HTMLScriptElement &HTMLScriptElement::operator = (const HTMLScriptElement &other)
00313 {
00314     HTMLElement::operator = (other);
00315     return *this;
00316 }
00317 
00318 HTMLScriptElement::~HTMLScriptElement()
00319 {
00320 }
00321 
00322 DOMString HTMLScriptElement::text() const
00323 {
00324     if(!impl) return DOMString();
00325     return ((HTMLScriptElementImpl *)impl)->text();
00326 }
00327 
00328 void HTMLScriptElement::setText( const DOMString &value )
00329 {
00330     if(impl) ((HTMLScriptElementImpl *)impl)->setText(value);
00331 }
00332 
00333 DOMString HTMLScriptElement::htmlFor() const
00334 {
00335     // DOM Level 1 says: reserved for future use...
00336     return DOMString();
00337 }
00338 
00339 void HTMLScriptElement::setHtmlFor( const DOMString &/*value*/ )
00340 {
00341     // DOM Level 1 says: reserved for future use...
00342 }
00343 
00344 DOMString HTMLScriptElement::event() const
00345 {
00346     // DOM Level 1 says: reserved for future use...
00347     return DOMString();
00348 }
00349 
00350 void HTMLScriptElement::setEvent( const DOMString &/*value*/ )
00351 {
00352     // DOM Level 1 says: reserved for future use...
00353 }
00354 
00355 DOMString HTMLScriptElement::charset() const
00356 {
00357     if(!impl) return DOMString();
00358     return ((ElementImpl *)impl)->getAttribute(ATTR_CHARSET);
00359 }
00360 
00361 void HTMLScriptElement::setCharset( const DOMString &value )
00362 {
00363     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHARSET, value);
00364 }
00365 
00366 bool HTMLScriptElement::defer() const
00367 {
00368     if(!impl) return 0;
00369     return !((ElementImpl *)impl)->getAttribute(ATTR_DEFER).isNull();
00370 }
00371 
00372 void HTMLScriptElement::setDefer( bool _defer )
00373 {
00374 
00375     if(impl)
00376         ((ElementImpl *)impl)->setAttribute(ATTR_DEFER,_defer ? "" : 0);
00377 }
00378 
00379 DOMString HTMLScriptElement::src() const
00380 {
00381     if(!impl) return DOMString();
00382     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_SRC);
00383     return !s.isNull() ? impl->document()->completeURL(s.string()) : s;
00384 }
00385 
00386 void HTMLScriptElement::setSrc( const DOMString &value )
00387 {
00388     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SRC, value);
00389 }
00390 
00391 DOMString HTMLScriptElement::type() const
00392 {
00393     if(!impl) return DOMString();
00394     return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
00395 }
00396 
00397 void HTMLScriptElement::setType( const DOMString &value )
00398 {
00399     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
00400 }
00401 
00402 // --------------------------------------------------------------------------
00403 
00404 HTMLStyleElement::HTMLStyleElement() : HTMLElement()
00405 {
00406 }
00407 
00408 HTMLStyleElement::HTMLStyleElement(const HTMLStyleElement &other) : HTMLElement(other)
00409 {
00410 }
00411 
00412 HTMLStyleElement::HTMLStyleElement(HTMLStyleElementImpl *impl) : HTMLElement(impl)
00413 {
00414 }
00415 
00416 HTMLStyleElement &HTMLStyleElement::operator = (const Node &other)
00417 {
00418     assignOther( other, ID_STYLE );
00419     return *this;
00420 }
00421 
00422 HTMLStyleElement &HTMLStyleElement::operator = (const HTMLStyleElement &other)
00423 {
00424     HTMLElement::operator = (other);
00425     return *this;
00426 }
00427 
00428 HTMLStyleElement::~HTMLStyleElement()
00429 {
00430 }
00431 
00432 bool HTMLStyleElement::disabled() const
00433 {
00434     if(!impl) return 0;
00435     return !((HTMLStyleElementImpl *)impl)->getAttribute(ATTR_DISABLED).isNull();
00436 }
00437 
00438 void HTMLStyleElement::setDisabled( bool _disabled )
00439 {
00440 
00441     if(impl)
00442         ((ElementImpl *)impl)->setAttribute(ATTR_DISABLED,_disabled ? "" : 0);
00443 }
00444 
00445 DOMString HTMLStyleElement::media() const
00446 {
00447     if(!impl) return DOMString();
00448     return ((ElementImpl *)impl)->getAttribute(ATTR_MEDIA);
00449 }
00450 
00451 void HTMLStyleElement::setMedia( const DOMString &value )
00452 {
00453     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_MEDIA, value);
00454 }
00455 
00456 DOMString HTMLStyleElement::type() const
00457 {
00458     if(!impl) return DOMString();
00459     return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
00460 }
00461 
00462 void HTMLStyleElement::setType( const DOMString &value )
00463 {
00464     if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
00465 }
00466 
00467 StyleSheet HTMLStyleElement::sheet() const
00468 {
00469     if(!impl) return 0;
00470     return ((HTMLStyleElementImpl *)impl)->sheet();
00471 }
00472 
00473 
00474 // --------------------------------------------------------------------------
00475 
00476 HTMLTitleElement::HTMLTitleElement() : HTMLElement()
00477 {
00478 }
00479 
00480 HTMLTitleElement::HTMLTitleElement(const HTMLTitleElement &other) : HTMLElement(other)
00481 {
00482 }
00483 
00484 HTMLTitleElement::HTMLTitleElement(HTMLTitleElementImpl *impl) : HTMLElement(impl)
00485 {
00486 }
00487 
00488 HTMLTitleElement &HTMLTitleElement::operator = (const Node &other)
00489 {
00490     assignOther( other, ID_TITLE );
00491     return *this;
00492 }
00493 
00494 HTMLTitleElement &HTMLTitleElement::operator = (const HTMLTitleElement &other)
00495 {
00496     HTMLElement::operator = (other);
00497     return *this;
00498 }
00499 
00500 HTMLTitleElement::~HTMLTitleElement()
00501 {
00502 }
00503 
00504 DOMString HTMLTitleElement::text() const
00505 {
00506     if(!impl) return DOMString();
00507     return ((HTMLTitleElementImpl *)impl)->text();
00508 }
00509 
00510 void HTMLTitleElement::setText( const DOMString &value )
00511 {
00512     if(impl) ((HTMLTitleElementImpl *)impl)->setText(value);
00513 }
00514 

KHTML

Skip menu "KHTML"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDEWebKit
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • KPty
  • Kross
  • KUnitConversion
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.7.3
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal