26#include "dom/html_block.h"
27#include "dom/html_misc.h"
28#include "html/html_blockimpl.h"
29#include "html/html_miscimpl.h"
33#include "misc/htmlhashes.h"
35HTMLBlockquoteElement::HTMLBlockquoteElement()
45HTMLBlockquoteElement::HTMLBlockquoteElement(HTMLElementImpl *impl)
52 assignOther( other, ID_BLOCKQUOTE );
58 HTMLElement::operator = (other);
62HTMLBlockquoteElement::~HTMLBlockquoteElement()
69 return ((ElementImpl *)impl)->getAttribute(ATTR_CITE);
74 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CITE, value);
79HTMLDivElement::HTMLDivElement()
89HTMLDivElement::HTMLDivElement(HTMLDivElementImpl *impl)
96 assignOther( other, ID_DIV );
102 HTMLElement::operator = (other);
106HTMLDivElement::~HTMLDivElement()
113 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
118 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
123HTMLHRElement::HTMLHRElement()
133HTMLHRElement::HTMLHRElement(HTMLHRElementImpl *impl)
140 assignOther( other, ID_HR );
146 HTMLElement::operator = (other);
150HTMLHRElement::~HTMLHRElement()
157 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
162 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
167 if(!impl)
return false;
168 return !((ElementImpl *)impl)->getAttribute(ATTR_NOSHADE).isNull();
178 ((ElementImpl *)impl)->setAttribute(ATTR_NOSHADE, str);
185 return ((ElementImpl *)impl)->getAttribute(ATTR_SIZE);
190 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SIZE, value);
196 return ((ElementImpl *)impl)->getAttribute(ATTR_WIDTH);
201 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_WIDTH, value);
206HTMLHeadingElement::HTMLHeadingElement()
216HTMLHeadingElement::HTMLHeadingElement(HTMLElementImpl *impl)
223 if(other.elementId() != ID_H1 &&
224 other.elementId() != ID_H2 &&
225 other.elementId() != ID_H3 &&
226 other.elementId() != ID_H4 &&
227 other.elementId() != ID_H5 &&
228 other.elementId() != ID_H6 )
230 if ( impl ) impl->deref();
233 Node::operator = (other);
240 HTMLElement::operator = (other);
244HTMLHeadingElement::~HTMLHeadingElement()
251 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
256 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
261HTMLParagraphElement::HTMLParagraphElement() :
HTMLElement()
270HTMLParagraphElement::HTMLParagraphElement(HTMLElementImpl *impl)
277 assignOther( other, ID_P );
283 HTMLElement::operator = (other);
287HTMLParagraphElement::~HTMLParagraphElement()
294 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
299 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
313HTMLPreElement::HTMLPreElement(HTMLPreElementImpl *impl)
320 assignOther( other, ID_PRE );
326 HTMLElement::operator = (other);
330HTMLPreElement::~HTMLPreElement()
337 DOMString w = ((ElementImpl *)impl)->getAttribute(ATTR_WIDTH);
346 aStr.sprintf(
"%ld", _width);
348 ((ElementImpl *)impl)->setAttribute(ATTR_WIDTH, value);
353HTMLLayerElement::HTMLLayerElement() :
HTMLElement()
362HTMLLayerElement::HTMLLayerElement(HTMLLayerElementImpl *impl)
369 assignOther( other, ID_LAYER );
375 HTMLElement::operator = (other);
379HTMLLayerElement::~HTMLLayerElement()
386 DOMString t = ((ElementImpl *)impl)->getAttribute(ATTR_TOP);
395 aStr.sprintf(
"%ld", _top);
397 ((ElementImpl *)impl)->setAttribute(ATTR_TOP, value);
403 DOMString l = ((ElementImpl *)impl)->getAttribute(ATTR_LEFT);
412 aStr.sprintf(
"%ld", _left);
414 ((ElementImpl *)impl)->setAttribute(ATTR_LEFT, value);
420 return ((ElementImpl *)impl)->getAttribute(ATTR_VISIBILITY);
425 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VISIBILITY, value);
431 return ((ElementImpl *)impl)->getAttribute(ATTR_BGCOLOR);
436 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BGCOLOR, value);
This class implements the basic string we use in the DOM.
??? See the BLOCKQUOTE element definition in HTML 4.0.
DOMString cite() const
A URI designating a document that describes the reason for the change.
void setCite(const DOMString &)
see cite
An HTMLCollection is a list of nodes.
void setAlign(const DOMString &)
see align
DOMString align() const
Horizontal text alignment.
All HTML element interfaces derive from this class.
Create a horizontal rule.
bool noShade() const
Indicates to the user agent that there should be no shading in the rendering of this element.
void setAlign(const DOMString &)
see align
void setNoShade(bool)
see noShade
DOMString width() const
The width of the rule.
void setSize(const DOMString &)
see size
DOMString align() const
Align the rule on the page.
void setWidth(const DOMString &)
see width
DOMString size() const
The height of the rule.
For the H1 to H6 elements.
void setAlign(const DOMString &)
see align
DOMString align() const
Horizontal text alignment.
Layer container for Netscape 4.x compatability.
void setBgColor(const DOMString &)
see bgColor
long top() const
The absolute position of the layer from the top.
long left() const
The absolute position of the layer from the left.
void setVisibility(const DOMString &)
see visibility
HTMLCollection layers() const
The collection of sub-layers.
DOMString visibility() const
The visibility of layers is either "show" or "hide".
DOMString bgColor() const
The background color of the layer.
void setLeft(long)
see left
DOMString align() const
Horizontal text alignment.
void setAlign(const DOMString &)
see align
long width() const
Fixed width for content.
void setWidth(long)
see width
The Node interface is the primary datatype for the entire Document Object Model.
The Document Object Model (DOM) is divided into two parts, the COREDOM core DOM, specifying some core...