html_list.cpp
// --------------------------------------------------------------------------
#include "dom/html_list.h"
#include "html/html_listimpl.h"
#include "misc/htmlhashes.h"
using namespace DOM;
HTMLDListElement::HTMLDListElement() : HTMLElement()
{
}
HTMLDListElement::HTMLDListElement(const HTMLDListElement &other) : HTMLElement(other)
{
}
HTMLDListElement::HTMLDListElement(HTMLDListElementImpl *impl) : HTMLElement(impl)
{
}
HTMLDListElement &HTMLDListElement::operator = (const Node &other)
{
assignOther( other, ID_DL );
return *this;
}
HTMLDListElement &HTMLDListElement::operator = (const HTMLDListElement &other)
{
HTMLElement::operator = (other);
return *this;
}
HTMLDListElement::~HTMLDListElement()
{
}
bool HTMLDListElement::compact() const
{
if(!impl) return 0;
return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
}
void HTMLDListElement::setCompact( bool _compact )
{
if(impl)
{
DOMString str;
if( _compact )
str = "";
((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
}
}
// --------------------------------------------------------------------------
HTMLDirectoryElement::HTMLDirectoryElement() : HTMLElement()
{
}
HTMLDirectoryElement::HTMLDirectoryElement(const HTMLDirectoryElement &other) : HTMLElement(other)
{
}
HTMLDirectoryElement::HTMLDirectoryElement(HTMLDirectoryElementImpl *impl) : HTMLElement(impl)
{
}
HTMLDirectoryElement &HTMLDirectoryElement::operator = (const Node &other)
{
assignOther( other, ID_DIR );
return *this;
}
HTMLDirectoryElement &HTMLDirectoryElement::operator = (const HTMLDirectoryElement &other)
{
HTMLElement::operator = (other);
return *this;
}
HTMLDirectoryElement::~HTMLDirectoryElement()
{
}
bool HTMLDirectoryElement::compact() const
{
if(!impl) return 0;
return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
}
void HTMLDirectoryElement::setCompact( bool _compact )
{
if(impl)
{
DOMString str;
if( _compact )
str = "";
((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
}
}
// --------------------------------------------------------------------------
HTMLLIElement::HTMLLIElement() : HTMLElement()
{
}
HTMLLIElement::HTMLLIElement(const HTMLLIElement &other) : HTMLElement(other)
{
}
HTMLLIElement::HTMLLIElement(HTMLLIElementImpl *impl) : HTMLElement(impl)
{
}
HTMLLIElement &HTMLLIElement::operator = (const Node &other)
{
assignOther( other, ID_LI );
return *this;
}
HTMLLIElement &HTMLLIElement::operator = (const HTMLLIElement &other)
{
HTMLElement::operator = (other);
return *this;
}
HTMLLIElement::~HTMLLIElement()
{
}
DOMString HTMLLIElement::type() const
{
if(!impl) return DOMString();
return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
}
void HTMLLIElement::setType( const DOMString &value )
{
if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
}
long HTMLLIElement::value() const
{
if(!impl) return 0;
return ((ElementImpl *)impl)->getAttribute(ATTR_VALUE).toInt();
}
void HTMLLIElement::setValue( long _value )
{
if(impl) {
DOMString value(QString::number(_value));
((ElementImpl *)impl)->setAttribute(ATTR_VALUE,value);
}
}
// --------------------------------------------------------------------------
HTMLMenuElement::HTMLMenuElement() : HTMLElement()
{
}
HTMLMenuElement::HTMLMenuElement(const HTMLMenuElement &other) : HTMLElement(other)
{
}
HTMLMenuElement::HTMLMenuElement(HTMLMenuElementImpl *impl) : HTMLElement(impl)
{
}
HTMLMenuElement &HTMLMenuElement::operator = (const Node &other)
{
assignOther( other, ID_MENU );
return *this;
}
HTMLMenuElement &HTMLMenuElement::operator = (const HTMLMenuElement &other)
{
HTMLElement::operator = (other);
return *this;
}
HTMLMenuElement::~HTMLMenuElement()
{
}
bool HTMLMenuElement::compact() const
{
if(!impl) return 0;
return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
}
void HTMLMenuElement::setCompact( bool _compact )
{
if(impl)
{
DOMString str;
if( _compact )
str = "";
((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
}
}
// --------------------------------------------------------------------------
HTMLOListElement::HTMLOListElement() : HTMLElement()
{
}
HTMLOListElement::HTMLOListElement(const HTMLOListElement &other) : HTMLElement(other)
{
}
HTMLOListElement::HTMLOListElement(HTMLOListElementImpl *impl) : HTMLElement(impl)
{
}
HTMLOListElement &HTMLOListElement::operator = (const Node &other)
{
assignOther( other, ID_OL );
return *this;
}
HTMLOListElement &HTMLOListElement::operator = (const HTMLOListElement &other)
{
HTMLElement::operator = (other);
return *this;
}
HTMLOListElement::~HTMLOListElement()
{
}
bool HTMLOListElement::compact() const
{
if(!impl) return 0;
return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
}
void HTMLOListElement::setCompact( bool _compact )
{
if(impl)
{
DOMString str;
if( _compact )
str = "";
((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
}
}
long HTMLOListElement::start() const
{
if(!impl) return 0;
return ((ElementImpl *)impl)->getAttribute(ATTR_START).toInt();
}
void HTMLOListElement::setStart( long _start )
{
if(impl) {
DOMString value(QString::number(_start));
((ElementImpl *)impl)->setAttribute(ATTR_START,value);
}
}
DOMString HTMLOListElement::type() const
{
if(!impl) return DOMString();
return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
}
void HTMLOListElement::setType( const DOMString &value )
{
if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
}
// --------------------------------------------------------------------------
HTMLUListElement::HTMLUListElement() : HTMLElement()
{
}
HTMLUListElement::HTMLUListElement(const HTMLUListElement &other) : HTMLElement(other)
{
}
HTMLUListElement::HTMLUListElement(HTMLUListElementImpl *impl) : HTMLElement(impl)
{
}
HTMLUListElement &HTMLUListElement::operator = (const Node &other)
{
assignOther( other, ID_UL );
return *this;
}
HTMLUListElement &HTMLUListElement::operator = (const HTMLUListElement &other)
{
HTMLElement::operator = (other);
return *this;
}
HTMLUListElement::~HTMLUListElement()
{
}
bool HTMLUListElement::compact() const
{
if(!impl) return 0;
return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
}
void HTMLUListElement::setCompact( bool _compact )
{
if(impl)
{
DOMString str;
if( _compact )
str = "";
((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
}
}
DOMString HTMLUListElement::type() const
{
if(!impl) return DOMString();
return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
}
void HTMLUListElement::setType( const DOMString &value )
{
if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
}
DOM::HTMLLIElement::type
DOMString type() const
List item bullet style.
Definition: html_list.cpp:152
DOM::HTMLOListElement::setType
void setType(const DOMString &)
see type
Definition: html_list.cpp:292
DOM::Node
The Node interface is the primary datatype for the entire Document Object Model.
Definition: dom_node.h:274
DOM::HTMLDirectoryElement
Directory list.
Definition: html_list.h:92
DOM::HTMLOListElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:260
DOM::HTMLLIElement
List item.
Definition: html_list.h:131
DOM::HTMLLIElement::value
long value() const
Reset sequence number when used in OL See the value attribute definition in HTML 4...
Definition: html_list.cpp:163
DOM::HTMLUListElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:333
DOM::HTMLUListElement::type
DOMString type() const
Bullet style.
Definition: html_list.cpp:344
DOM::HTMLUListElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:327
DOM::HTMLOListElement::type
DOMString type() const
Numbering style.
Definition: html_list.cpp:286
DOM::HTMLLIElement::setType
void setType(const DOMString &)
see type
Definition: html_list.cpp:158
DOM::HTMLOListElement
Ordered list.
Definition: html_list.h:226
DOM::HTMLUListElement::setType
void setType(const DOMString &)
see type
Definition: html_list.cpp:350
DOM::HTMLDListElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:58
DOM::HTMLLIElement::setValue
void setValue(long)
see value
Definition: html_list.cpp:169
DOM::DOMString
This class implements the basic string we use in the DOM.
Definition: dom_string.h:43
DOM::HTMLDListElement
Definition list.
Definition: html_list.h:52
DOM::HTMLDirectoryElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:111
DOM::HTMLOListElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:254
DOM::HTMLOListElement::start
long start() const
Starting sequence number.
Definition: html_list.cpp:271
DOM::HTMLDirectoryElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:105
DOM::HTMLOListElement::setStart
void setStart(long)
see start
Definition: html_list.cpp:277
DOM::HTMLUListElement
Unordered list.
Definition: html_list.h:294
DOM::HTMLElement
All HTML element interfaces derive from this class.
Definition: html_element.h:69
DOM::HTMLDListElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:64

KDE Home | KDE Accessibility Home | Description of Access Keys