• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdehtml
 

tdehtml

  • tdehtml
  • dom
html_list.cpp
1
22// --------------------------------------------------------------------------
23
24#include "dom/html_list.h"
25#include "html/html_listimpl.h"
26#include "misc/htmlhashes.h"
27
28using namespace DOM;
29
30HTMLDListElement::HTMLDListElement() : HTMLElement()
31{
32}
33
34HTMLDListElement::HTMLDListElement(const HTMLDListElement &other) : HTMLElement(other)
35{
36}
37
38HTMLDListElement::HTMLDListElement(HTMLDListElementImpl *impl) : HTMLElement(impl)
39{
40}
41
42HTMLDListElement &HTMLDListElement::operator = (const Node &other)
43{
44 assignOther( other, ID_DL );
45 return *this;
46}
47
48HTMLDListElement &HTMLDListElement::operator = (const HTMLDListElement &other)
49{
50 HTMLElement::operator = (other);
51 return *this;
52}
53
54HTMLDListElement::~HTMLDListElement()
55{
56}
57
58bool HTMLDListElement::compact() const
59{
60 if(!impl) return 0;
61 return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
62}
63
64void HTMLDListElement::setCompact( bool _compact )
65{
66 if(impl)
67 {
68 DOMString str;
69 if( _compact )
70 str = "";
71 ((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
72 }
73}
74
75// --------------------------------------------------------------------------
76
77HTMLDirectoryElement::HTMLDirectoryElement() : HTMLElement()
78{
79}
80
81HTMLDirectoryElement::HTMLDirectoryElement(const HTMLDirectoryElement &other) : HTMLElement(other)
82{
83}
84
85HTMLDirectoryElement::HTMLDirectoryElement(HTMLDirectoryElementImpl *impl) : HTMLElement(impl)
86{
87}
88
89HTMLDirectoryElement &HTMLDirectoryElement::operator = (const Node &other)
90{
91 assignOther( other, ID_DIR );
92 return *this;
93}
94
95HTMLDirectoryElement &HTMLDirectoryElement::operator = (const HTMLDirectoryElement &other)
96{
97 HTMLElement::operator = (other);
98 return *this;
99}
100
101HTMLDirectoryElement::~HTMLDirectoryElement()
102{
103}
104
105bool HTMLDirectoryElement::compact() const
106{
107 if(!impl) return 0;
108 return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
109}
110
111void HTMLDirectoryElement::setCompact( bool _compact )
112{
113 if(impl)
114 {
115 DOMString str;
116 if( _compact )
117 str = "";
118 ((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
119 }
120}
121
122// --------------------------------------------------------------------------
123
124HTMLLIElement::HTMLLIElement() : HTMLElement()
125{
126}
127
128HTMLLIElement::HTMLLIElement(const HTMLLIElement &other) : HTMLElement(other)
129{
130}
131
132HTMLLIElement::HTMLLIElement(HTMLLIElementImpl *impl) : HTMLElement(impl)
133{
134}
135
136HTMLLIElement &HTMLLIElement::operator = (const Node &other)
137{
138 assignOther( other, ID_LI );
139 return *this;
140}
141
142HTMLLIElement &HTMLLIElement::operator = (const HTMLLIElement &other)
143{
144 HTMLElement::operator = (other);
145 return *this;
146}
147
148HTMLLIElement::~HTMLLIElement()
149{
150}
151
152DOMString HTMLLIElement::type() const
153{
154 if(!impl) return DOMString();
155 return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
156}
157
158void HTMLLIElement::setType( const DOMString &value )
159{
160 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
161}
162
163long HTMLLIElement::value() const
164{
165 if(!impl) return 0;
166 return ((ElementImpl *)impl)->getAttribute(ATTR_VALUE).toInt();
167}
168
169void HTMLLIElement::setValue( long _value )
170{
171 if(impl) {
172 DOMString value(TQString::number(_value));
173 ((ElementImpl *)impl)->setAttribute(ATTR_VALUE,value);
174 }
175}
176
177// --------------------------------------------------------------------------
178
179HTMLMenuElement::HTMLMenuElement() : HTMLElement()
180{
181}
182
183HTMLMenuElement::HTMLMenuElement(const HTMLMenuElement &other) : HTMLElement(other)
184{
185}
186
187HTMLMenuElement::HTMLMenuElement(HTMLMenuElementImpl *impl) : HTMLElement(impl)
188{
189}
190
191HTMLMenuElement &HTMLMenuElement::operator = (const Node &other)
192{
193 assignOther( other, ID_MENU );
194 return *this;
195}
196
197HTMLMenuElement &HTMLMenuElement::operator = (const HTMLMenuElement &other)
198{
199 HTMLElement::operator = (other);
200 return *this;
201}
202
203HTMLMenuElement::~HTMLMenuElement()
204{
205}
206
207bool HTMLMenuElement::compact() const
208{
209 if(!impl) return 0;
210 return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
211}
212
213void HTMLMenuElement::setCompact( bool _compact )
214{
215 if(impl)
216 {
217 DOMString str;
218 if( _compact )
219 str = "";
220 ((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
221 }
222}
223
224// --------------------------------------------------------------------------
225
226HTMLOListElement::HTMLOListElement() : HTMLElement()
227{
228}
229
230HTMLOListElement::HTMLOListElement(const HTMLOListElement &other) : HTMLElement(other)
231{
232}
233
234HTMLOListElement::HTMLOListElement(HTMLOListElementImpl *impl) : HTMLElement(impl)
235{
236}
237
238HTMLOListElement &HTMLOListElement::operator = (const Node &other)
239{
240 assignOther( other, ID_OL );
241 return *this;
242}
243
244HTMLOListElement &HTMLOListElement::operator = (const HTMLOListElement &other)
245{
246 HTMLElement::operator = (other);
247 return *this;
248}
249
250HTMLOListElement::~HTMLOListElement()
251{
252}
253
254bool HTMLOListElement::compact() const
255{
256 if(!impl) return 0;
257 return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
258}
259
260void HTMLOListElement::setCompact( bool _compact )
261{
262 if(impl)
263 {
264 DOMString str;
265 if( _compact )
266 str = "";
267 ((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
268 }
269}
270
271long HTMLOListElement::start() const
272{
273 if(!impl) return 0;
274 return ((ElementImpl *)impl)->getAttribute(ATTR_START).toInt();
275}
276
277void HTMLOListElement::setStart( long _start )
278{
279
280 if(impl) {
281 DOMString value(TQString::number(_start));
282 ((ElementImpl *)impl)->setAttribute(ATTR_START,value);
283 }
284}
285
286DOMString HTMLOListElement::type() const
287{
288 if(!impl) return DOMString();
289 return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
290}
291
292void HTMLOListElement::setType( const DOMString &value )
293{
294 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
295}
296
297// --------------------------------------------------------------------------
298
299HTMLUListElement::HTMLUListElement() : HTMLElement()
300{
301}
302
303HTMLUListElement::HTMLUListElement(const HTMLUListElement &other) : HTMLElement(other)
304{
305}
306
307HTMLUListElement::HTMLUListElement(HTMLUListElementImpl *impl) : HTMLElement(impl)
308{
309}
310
311HTMLUListElement &HTMLUListElement::operator = (const Node &other)
312{
313 assignOther( other, ID_UL );
314 return *this;
315}
316
317HTMLUListElement &HTMLUListElement::operator = (const HTMLUListElement &other)
318{
319 HTMLElement::operator = (other);
320 return *this;
321}
322
323HTMLUListElement::~HTMLUListElement()
324{
325}
326
327bool HTMLUListElement::compact() const
328{
329 if(!impl) return 0;
330 return !((ElementImpl *)impl)->getAttribute(ATTR_COMPACT).isNull();
331}
332
333void HTMLUListElement::setCompact( bool _compact )
334{
335 if(impl)
336 {
337 DOMString str;
338 if( _compact )
339 str = "";
340 ((ElementImpl *)impl)->setAttribute(ATTR_COMPACT, str);
341 }
342}
343
344DOMString HTMLUListElement::type() const
345{
346 if(!impl) return DOMString();
347 return ((ElementImpl *)impl)->getAttribute(ATTR_TYPE);
348}
349
350void HTMLUListElement::setType( const DOMString &value )
351{
352 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_TYPE, value);
353}
354
DOM::DOMString
This class implements the basic string we use in the DOM.
Definition: dom_string.h:44
DOM::HTMLDListElement
Definition list.
Definition: html_list.h:53
DOM::HTMLDListElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:64
DOM::HTMLDListElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:58
DOM::HTMLDirectoryElement
Directory list.
Definition: html_list.h:93
DOM::HTMLDirectoryElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:111
DOM::HTMLDirectoryElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:105
DOM::HTMLElement
All HTML element interfaces derive from this class.
Definition: html_element.h:70
DOM::HTMLLIElement
List item.
Definition: html_list.h:132
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::HTMLLIElement::setType
void setType(const DOMString &)
see type
Definition: html_list.cpp:158
DOM::HTMLLIElement::type
DOMString type() const
List item bullet style.
Definition: html_list.cpp:152
DOM::HTMLLIElement::setValue
void setValue(long)
see value
Definition: html_list.cpp:169
DOM::HTMLMenuElement
Menu list.
Definition: html_list.h:187
DOM::HTMLMenuElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:207
DOM::HTMLMenuElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:213
DOM::HTMLOListElement
Ordered list.
Definition: html_list.h:227
DOM::HTMLOListElement::type
DOMString type() const
Numbering style.
Definition: html_list.cpp:286
DOM::HTMLOListElement::setStart
void setStart(long)
see start
Definition: html_list.cpp:277
DOM::HTMLOListElement::setType
void setType(const DOMString &)
see type
Definition: html_list.cpp:292
DOM::HTMLOListElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:254
DOM::HTMLOListElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:260
DOM::HTMLOListElement::start
long start() const
Starting sequence number.
Definition: html_list.cpp:271
DOM::HTMLUListElement
Unordered list.
Definition: html_list.h:295
DOM::HTMLUListElement::type
DOMString type() const
Bullet style.
Definition: html_list.cpp:344
DOM::HTMLUListElement::setType
void setType(const DOMString &)
see type
Definition: html_list.cpp:350
DOM::HTMLUListElement::setCompact
void setCompact(bool)
see compact
Definition: html_list.cpp:333
DOM::HTMLUListElement::compact
bool compact() const
Reduce spacing between list items.
Definition: html_list.cpp:327
DOM::Node
The Node interface is the primary datatype for the entire Document Object Model.
Definition: dom_node.h:275
DOM
The Document Object Model (DOM) is divided into two parts, the COREDOM core DOM, specifying some core...
Definition: design.h:57

tdehtml

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

tdehtml

Skip menu "tdehtml"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdehtml by doxygen 1.9.4
This website is maintained by Timothy Pearson.