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

tdehtml

  • tdehtml
  • dom
html_table.cpp
1
22// --------------------------------------------------------------------------
23
24#include "dom/html_misc.h"
25#include "dom/html_table.h"
26#include "dom/dom_exception.h"
27
28#include "html/html_miscimpl.h"
29#include "html/html_tableimpl.h"
30#include "misc/htmlhashes.h"
31
32using namespace DOM;
33
34HTMLTableCaptionElement::HTMLTableCaptionElement() : HTMLElement()
35{
36}
37
38HTMLTableCaptionElement::HTMLTableCaptionElement(const HTMLTableCaptionElement &other) : HTMLElement(other)
39{
40}
41
42HTMLTableCaptionElement::HTMLTableCaptionElement(HTMLTableCaptionElementImpl *impl) : HTMLElement(impl)
43{
44}
45
46HTMLTableCaptionElement &HTMLTableCaptionElement::operator = (const Node &other)
47{
48 assignOther( other, ID_CAPTION );
49 return *this;
50}
51
52HTMLTableCaptionElement &HTMLTableCaptionElement::operator = (const HTMLTableCaptionElement &other)
53{
54 HTMLElement::operator = (other);
55 return *this;
56}
57
58HTMLTableCaptionElement::~HTMLTableCaptionElement()
59{
60}
61
62DOMString HTMLTableCaptionElement::align() const
63{
64 if(!impl) return DOMString();
65 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
66}
67
68void HTMLTableCaptionElement::setAlign( const DOMString &value )
69{
70 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
71}
72
73// --------------------------------------------------------------------------
74
75HTMLTableCellElement::HTMLTableCellElement() : HTMLElement()
76{
77}
78
79HTMLTableCellElement::HTMLTableCellElement(const HTMLTableCellElement &other) : HTMLElement(other)
80{
81}
82
83HTMLTableCellElement::HTMLTableCellElement(HTMLTableCellElementImpl *impl) : HTMLElement(impl)
84{
85}
86
87HTMLTableCellElement &HTMLTableCellElement::operator = (const Node &other)
88{
89 if( other.elementId() != ID_TD &&
90 other.elementId() != ID_TH )
91 {
92 if ( impl ) impl->deref();
93 impl = 0;
94 } else {
95 Node::operator = (other);
96 }
97 return *this;
98}
99
100HTMLTableCellElement &HTMLTableCellElement::operator = (const HTMLTableCellElement &other)
101{
102 HTMLElement::operator = (other);
103 return *this;
104}
105
106HTMLTableCellElement::~HTMLTableCellElement()
107{
108}
109
110long HTMLTableCellElement::cellIndex() const
111{
112 if(!impl) return 0;
113 return ((HTMLTableCellElementImpl *)impl)->cellIndex();
114}
115
116void HTMLTableCellElement::setCellIndex( long /*_cellIndex*/ )
117{
118 throw DOMException(DOMException::NO_MODIFICATION_ALLOWED_ERR);
119}
120
121DOMString HTMLTableCellElement::abbr() const
122{
123 if(!impl) return DOMString();
124 return ((ElementImpl *)impl)->getAttribute(ATTR_ABBR);
125}
126
127void HTMLTableCellElement::setAbbr( const DOMString &value )
128{
129 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ABBR, value);
130}
131
132DOMString HTMLTableCellElement::align() const
133{
134 if(!impl) return DOMString();
135 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
136}
137
138void HTMLTableCellElement::setAlign( const DOMString &value )
139{
140 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
141}
142
143DOMString HTMLTableCellElement::axis() const
144{
145 if(!impl) return DOMString();
146 return ((ElementImpl *)impl)->getAttribute(ATTR_AXIS);
147}
148
149void HTMLTableCellElement::setAxis( const DOMString &value )
150{
151 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_AXIS, value);
152}
153
154DOMString HTMLTableCellElement::bgColor() const
155{
156 if(!impl) return DOMString();
157 return ((ElementImpl *)impl)->getAttribute(ATTR_BGCOLOR);
158}
159
160void HTMLTableCellElement::setBgColor( const DOMString &value )
161{
162 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BGCOLOR, value);
163}
164
165DOMString HTMLTableCellElement::ch() const
166{
167 if(!impl) return DOMString();
168 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAR);
169}
170
171void HTMLTableCellElement::setCh( const DOMString &value )
172{
173 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAR, value);
174}
175
176DOMString HTMLTableCellElement::chOff() const
177{
178 if(!impl) return DOMString();
179 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAROFF);
180}
181
182void HTMLTableCellElement::setChOff( const DOMString &value )
183{
184 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAROFF, value);
185}
186
187long HTMLTableCellElement::colSpan() const
188{
189 if(!impl) return 0;
190 return ((ElementImpl *)impl)->getAttribute(ATTR_COLSPAN).toInt();
191}
192
193void HTMLTableCellElement::setColSpan( long _colSpan )
194{
195 if(impl) {
196 DOMString value(TQString::number(_colSpan));
197 ((ElementImpl *)impl)->setAttribute(ATTR_COLSPAN,value);
198 }
199}
200
201DOMString HTMLTableCellElement::headers() const
202{
203 if(!impl) return DOMString();
204 return ((ElementImpl *)impl)->getAttribute(ATTR_HEADERS);
205}
206
207void HTMLTableCellElement::setHeaders( const DOMString &value )
208{
209 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HEADERS, value);
210}
211
212DOMString HTMLTableCellElement::height() const
213{
214 if(!impl) return DOMString();
215 return ((ElementImpl *)impl)->getAttribute(ATTR_HEIGHT);
216}
217
218void HTMLTableCellElement::setHeight( const DOMString &value )
219{
220 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_HEIGHT, value);
221}
222
223bool HTMLTableCellElement::noWrap() const
224{
225 if(!impl) return false;
226 return !((ElementImpl *)impl)->getAttribute(ATTR_NOWRAP).isNull();
227}
228
229void HTMLTableCellElement::setNoWrap( bool _noWrap )
230{
231 if(impl)
232 ((ElementImpl *)impl)->setAttribute(ATTR_NOWRAP, _noWrap ? "" : 0);
233}
234
235long HTMLTableCellElement::rowSpan() const
236{
237 if(!impl) return 0;
238 return ((ElementImpl *)impl)->getAttribute(ATTR_ROWSPAN).toInt();
239}
240
241void HTMLTableCellElement::setRowSpan( long _rowSpan )
242{
243 if(impl) {
244 DOMString value(TQString::number(_rowSpan));
245 ((ElementImpl *)impl)->setAttribute(ATTR_ROWSPAN,value);
246 }
247}
248
249DOMString HTMLTableCellElement::scope() const
250{
251 if(!impl) return DOMString();
252 return ((ElementImpl *)impl)->getAttribute(ATTR_SCOPE);
253}
254
255void HTMLTableCellElement::setScope( const DOMString &value )
256{
257 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SCOPE, value);
258}
259
260DOMString HTMLTableCellElement::vAlign() const
261{
262 if(!impl) return DOMString();
263 return ((ElementImpl *)impl)->getAttribute(ATTR_VALIGN);
264}
265
266void HTMLTableCellElement::setVAlign( const DOMString &value )
267{
268 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VALIGN, value);
269}
270
271DOMString HTMLTableCellElement::width() const
272{
273 if(!impl) return DOMString();
274 return ((ElementImpl *)impl)->getAttribute(ATTR_WIDTH);
275}
276
277void HTMLTableCellElement::setWidth( const DOMString &value )
278{
279 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_WIDTH, value);
280}
281
282// --------------------------------------------------------------------------
283
284HTMLTableColElement::HTMLTableColElement() : HTMLElement()
285{
286}
287
288HTMLTableColElement::HTMLTableColElement(const HTMLTableColElement &other) : HTMLElement(other)
289{
290}
291
292HTMLTableColElement::HTMLTableColElement(HTMLTableColElementImpl *impl) : HTMLElement(impl)
293{
294}
295
296HTMLTableColElement &HTMLTableColElement::operator = (const Node &other)
297{
298 if( other.elementId() != ID_COL &&
299 other.elementId() != ID_COLGROUP )
300 {
301 if ( impl ) impl->deref();
302 impl = 0;
303 } else {
304 Node::operator = (other);
305 }
306 return *this;
307}
308
309HTMLTableColElement &HTMLTableColElement::operator = (const HTMLTableColElement &other)
310{
311 HTMLElement::operator = (other);
312 return *this;
313}
314
315HTMLTableColElement::~HTMLTableColElement()
316{
317}
318
319DOMString HTMLTableColElement::align() const
320{
321 if(!impl) return DOMString();
322 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
323}
324
325void HTMLTableColElement::setAlign( const DOMString &value )
326{
327 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
328}
329
330DOMString HTMLTableColElement::ch() const
331{
332 if(!impl) return DOMString();
333 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAR);
334}
335
336void HTMLTableColElement::setCh( const DOMString &value )
337{
338 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAR, value);
339}
340
341DOMString HTMLTableColElement::chOff() const
342{
343 if(!impl) return DOMString();
344 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAROFF);
345}
346
347void HTMLTableColElement::setChOff( const DOMString &value )
348{
349 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAROFF, value);
350}
351
352long HTMLTableColElement::span() const
353{
354 if(!impl) return 0;
355 return ((ElementImpl *)impl)->getAttribute(ATTR_SPAN).toInt();
356}
357
358void HTMLTableColElement::setSpan( long _span )
359{
360 if(impl) {
361 DOMString value(TQString::number(_span));
362 ((ElementImpl *)impl)->setAttribute(ATTR_SPAN,value);
363 }
364}
365
366DOMString HTMLTableColElement::vAlign() const
367{
368 if(!impl) return DOMString();
369 return ((ElementImpl *)impl)->getAttribute(ATTR_VALIGN);
370}
371
372void HTMLTableColElement::setVAlign( const DOMString &value )
373{
374 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VALIGN, value);
375}
376
377DOMString HTMLTableColElement::width() const
378{
379 if(!impl) return DOMString();
380 return ((ElementImpl *)impl)->getAttribute(ATTR_WIDTH);
381}
382
383void HTMLTableColElement::setWidth( const DOMString &value )
384{
385 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_WIDTH, value);
386}
387
388// --------------------------------------------------------------------------
389
390HTMLTableElement::HTMLTableElement() : HTMLElement()
391{
392}
393
394HTMLTableElement::HTMLTableElement(const HTMLTableElement &other) : HTMLElement(other)
395{
396}
397
398HTMLTableElement::HTMLTableElement(HTMLTableElementImpl *impl) : HTMLElement(impl)
399{
400}
401
402HTMLTableElement &HTMLTableElement::operator = (const Node &other)
403{
404 assignOther( other, ID_TABLE );
405 return *this;
406}
407
408HTMLTableElement &HTMLTableElement::operator = (const HTMLTableElement &other)
409{
410 HTMLElement::operator = (other);
411 return *this;
412}
413
414HTMLTableElement::~HTMLTableElement()
415{
416}
417
418HTMLTableCaptionElement HTMLTableElement::caption() const
419{
420 if(!impl) return 0;
421 return ((HTMLTableElementImpl *)impl)->caption();
422}
423
424void HTMLTableElement::setCaption( const HTMLTableCaptionElement &_caption )
425{
426 if(impl)
427 ((HTMLTableElementImpl *)impl)
428 ->setCaption( ((HTMLTableCaptionElementImpl *)_caption.impl) );
429}
430
431HTMLTableSectionElement HTMLTableElement::tHead() const
432{
433 if(!impl) return 0;
434 return ((HTMLTableElementImpl *)impl)->tHead();
435}
436
437void HTMLTableElement::setTHead( const HTMLTableSectionElement &_tHead )
438{
439
440 if(impl)
441 ((HTMLTableElementImpl *)impl)
442 ->setTHead( ((HTMLTableSectionElementImpl *)_tHead.impl) );
443}
444
445HTMLTableSectionElement HTMLTableElement::tFoot() const
446{
447 if(!impl) return 0;
448 return ((HTMLTableElementImpl *)impl)->tFoot();
449}
450
451void HTMLTableElement::setTFoot( const HTMLTableSectionElement &_tFoot )
452{
453
454 if(impl)
455 ((HTMLTableElementImpl *)impl)
456 ->setTFoot( ((HTMLTableSectionElementImpl *)_tFoot.impl) );
457}
458
459HTMLCollection HTMLTableElement::rows() const
460{
461 if(!impl) return HTMLCollection();
462 return HTMLCollection(impl, HTMLCollectionImpl::TABLE_ROWS);
463}
464
465HTMLCollection HTMLTableElement::tBodies() const
466{
467 if(!impl) return HTMLCollection();
468 return HTMLCollection(impl, HTMLCollectionImpl::TABLE_TBODIES);
469}
470
471DOMString HTMLTableElement::align() const
472{
473 if(!impl) return DOMString();
474 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
475}
476
477void HTMLTableElement::setAlign( const DOMString &value )
478{
479 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
480}
481
482DOMString HTMLTableElement::bgColor() const
483{
484 if(!impl) return DOMString();
485 return ((ElementImpl *)impl)->getAttribute(ATTR_BGCOLOR);
486}
487
488void HTMLTableElement::setBgColor( const DOMString &value )
489{
490 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BGCOLOR, value);
491}
492
493DOMString HTMLTableElement::border() const
494{
495 if(!impl) return DOMString();
496 return ((ElementImpl *)impl)->getAttribute(ATTR_BORDER);
497}
498
499void HTMLTableElement::setBorder( const DOMString &value )
500{
501 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BORDER, value);
502}
503
504DOMString HTMLTableElement::cellPadding() const
505{
506 if(!impl) return DOMString();
507 return ((ElementImpl *)impl)->getAttribute(ATTR_CELLPADDING);
508}
509
510void HTMLTableElement::setCellPadding( const DOMString &value )
511{
512 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CELLPADDING, value);
513}
514
515DOMString HTMLTableElement::cellSpacing() const
516{
517 if(!impl) return DOMString();
518 return ((ElementImpl *)impl)->getAttribute(ATTR_CELLSPACING);
519}
520
521void HTMLTableElement::setCellSpacing( const DOMString &value )
522{
523 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CELLSPACING, value);
524}
525
526DOMString HTMLTableElement::frame() const
527{
528 if(!impl) return DOMString();
529 return ((ElementImpl *)impl)->getAttribute(ATTR_FRAME);
530}
531
532void HTMLTableElement::setFrame( const DOMString &value )
533{
534 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_FRAME, value);
535}
536
537DOMString HTMLTableElement::rules() const
538{
539 if(!impl) return DOMString();
540 return ((ElementImpl *)impl)->getAttribute(ATTR_RULES);
541}
542
543void HTMLTableElement::setRules( const DOMString &value )
544{
545 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_RULES, value);
546}
547
548DOMString HTMLTableElement::summary() const
549{
550 if(!impl) return DOMString();
551 return ((ElementImpl *)impl)->getAttribute(ATTR_SUMMARY);
552}
553
554void HTMLTableElement::setSummary( const DOMString &value )
555{
556 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_SUMMARY, value);
557}
558
559DOMString HTMLTableElement::width() const
560{
561 if(!impl) return DOMString();
562 return ((ElementImpl *)impl)->getAttribute(ATTR_WIDTH);
563}
564
565void HTMLTableElement::setWidth( const DOMString &value )
566{
567 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_WIDTH, value);
568}
569
570HTMLElement HTMLTableElement::createTHead( )
571{
572 if(!impl) return 0;
573 return ((HTMLTableElementImpl *)impl)->createTHead( );
574}
575
576void HTMLTableElement::deleteTHead( )
577{
578 if(impl)
579 ((HTMLTableElementImpl *)impl)->deleteTHead( );
580}
581
582HTMLElement HTMLTableElement::createTFoot( )
583{
584 if(!impl) return 0;
585 return ((HTMLTableElementImpl *)impl)->createTFoot( );
586}
587
588void HTMLTableElement::deleteTFoot( )
589{
590 if(impl)
591 ((HTMLTableElementImpl *)impl)->deleteTFoot( );
592}
593
594HTMLElement HTMLTableElement::createCaption( )
595{
596 if(!impl) return 0;
597 return ((HTMLTableElementImpl *)impl)->createCaption( );
598}
599
600void HTMLTableElement::deleteCaption( )
601{
602 if(impl)
603 ((HTMLTableElementImpl *)impl)->deleteCaption( );
604}
605
606HTMLElement HTMLTableElement::insertRow( long index )
607{
608 if(!impl) return 0;
609 int exceptioncode = 0;
610 HTMLElementImpl* ret = ((HTMLTableElementImpl *)impl)->insertRow( index, exceptioncode );
611 if (exceptioncode)
612 throw DOMException(exceptioncode);
613 return ret;
614}
615
616void HTMLTableElement::deleteRow( long index )
617{
618 int exceptioncode = 0;
619 if(impl)
620 ((HTMLTableElementImpl *)impl)->deleteRow( index, exceptioncode );
621 if (exceptioncode)
622 throw DOMException(exceptioncode);
623}
624
625// --------------------------------------------------------------------------
626
627HTMLTableRowElement::HTMLTableRowElement() : HTMLElement()
628{
629}
630
631HTMLTableRowElement::HTMLTableRowElement(const HTMLTableRowElement &other) : HTMLElement(other)
632{
633}
634
635HTMLTableRowElement::HTMLTableRowElement(HTMLTableRowElementImpl *impl) : HTMLElement(impl)
636{
637}
638
639HTMLTableRowElement &HTMLTableRowElement::operator = (const Node &other)
640{
641 assignOther( other, ID_TR );
642 return *this;
643}
644
645HTMLTableRowElement &HTMLTableRowElement::operator = (const HTMLTableRowElement &other)
646{
647 HTMLElement::operator = (other);
648 return *this;
649}
650
651HTMLTableRowElement::~HTMLTableRowElement()
652{
653}
654
655long HTMLTableRowElement::rowIndex() const
656{
657 if(!impl) return 0;
658 return ((HTMLTableRowElementImpl *)impl)->rowIndex();
659}
660
661void HTMLTableRowElement::setRowIndex( long /*_rowIndex*/ )
662{
663 throw DOMException(DOMException::NO_MODIFICATION_ALLOWED_ERR);
664}
665
666long HTMLTableRowElement::sectionRowIndex() const
667{
668 if(!impl) return 0;
669 return ((HTMLTableRowElementImpl *)impl)->sectionRowIndex();
670}
671
672void HTMLTableRowElement::setSectionRowIndex( long /*_sectionRowIndex*/ )
673{
674 throw DOMException(DOMException::NO_MODIFICATION_ALLOWED_ERR);
675}
676
677HTMLCollection HTMLTableRowElement::cells() const
678{
679 if(!impl) return HTMLCollection();
680 return HTMLCollection(impl, HTMLCollectionImpl::TR_CELLS);
681}
682
683void HTMLTableRowElement::setCells( const HTMLCollection & /*_cells*/ )
684{
685 throw DOMException(DOMException::NO_MODIFICATION_ALLOWED_ERR);
686}
687
688DOMString HTMLTableRowElement::align() const
689{
690 if(!impl) return DOMString();
691 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
692}
693
694void HTMLTableRowElement::setAlign( const DOMString &value )
695{
696 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
697}
698
699DOMString HTMLTableRowElement::bgColor() const
700{
701 if(!impl) return DOMString();
702 return ((ElementImpl *)impl)->getAttribute(ATTR_BGCOLOR);
703}
704
705void HTMLTableRowElement::setBgColor( const DOMString &value )
706{
707 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_BGCOLOR, value);
708}
709
710DOMString HTMLTableRowElement::ch() const
711{
712 if(!impl) return DOMString();
713 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAR);
714}
715
716void HTMLTableRowElement::setCh( const DOMString &value )
717{
718 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAR, value);
719}
720
721DOMString HTMLTableRowElement::chOff() const
722{
723 if(!impl) return DOMString();
724 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAROFF);
725}
726
727void HTMLTableRowElement::setChOff( const DOMString &value )
728{
729 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAROFF, value);
730}
731
732DOMString HTMLTableRowElement::vAlign() const
733{
734 if(!impl) return DOMString();
735 return ((ElementImpl *)impl)->getAttribute(ATTR_VALIGN);
736}
737
738void HTMLTableRowElement::setVAlign( const DOMString &value )
739{
740 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VALIGN, value);
741}
742
743HTMLElement HTMLTableRowElement::insertCell( long index )
744{
745 if(!impl) return 0;
746 int exceptioncode = 0;
747 HTMLElementImpl* ret = ((HTMLTableRowElementImpl *)impl)->insertCell( index, exceptioncode );
748 if (exceptioncode)
749 throw DOMException(exceptioncode);
750 return ret;
751}
752
753void HTMLTableRowElement::deleteCell( long index )
754{
755 int exceptioncode = 0;
756 if(impl)
757 ((HTMLTableRowElementImpl *)impl)->deleteCell( index, exceptioncode );
758 if (exceptioncode)
759 throw DOMException(exceptioncode);
760}
761
762// --------------------------------------------------------------------------
763
764HTMLTableSectionElement::HTMLTableSectionElement() : HTMLElement()
765{
766}
767
768HTMLTableSectionElement::HTMLTableSectionElement(const HTMLTableSectionElement &other) : HTMLElement(other)
769{
770}
771
772HTMLTableSectionElement::HTMLTableSectionElement(HTMLTableSectionElementImpl *impl) : HTMLElement(impl)
773{
774}
775
776HTMLTableSectionElement &HTMLTableSectionElement::operator = (const Node &other)
777{
778 if(other.elementId() != ID_TBODY &&
779 other.elementId() != ID_THEAD &&
780 other.elementId() != ID_TFOOT )
781 {
782 if ( impl ) impl->deref();
783 impl = 0;
784 } else {
785 Node::operator = (other);
786 }
787 return *this;
788}
789
790HTMLTableSectionElement &HTMLTableSectionElement::operator = (const HTMLTableSectionElement &other)
791{
792 HTMLElement::operator = (other);
793 return *this;
794}
795
796HTMLTableSectionElement::~HTMLTableSectionElement()
797{
798}
799
800DOMString HTMLTableSectionElement::align() const
801{
802 if(!impl) return DOMString();
803 return ((ElementImpl *)impl)->getAttribute(ATTR_ALIGN);
804}
805
806void HTMLTableSectionElement::setAlign( const DOMString &value )
807{
808 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_ALIGN, value);
809}
810
811DOMString HTMLTableSectionElement::ch() const
812{
813 if(!impl) return DOMString();
814 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAR);
815}
816
817void HTMLTableSectionElement::setCh( const DOMString &value )
818{
819 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAR, value);
820}
821
822DOMString HTMLTableSectionElement::chOff() const
823{
824 if(!impl) return DOMString();
825 return ((ElementImpl *)impl)->getAttribute(ATTR_CHAROFF);
826}
827
828void HTMLTableSectionElement::setChOff( const DOMString &value )
829{
830 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_CHAROFF, value);
831}
832
833DOMString HTMLTableSectionElement::vAlign() const
834{
835 if(!impl) return DOMString();
836 return ((ElementImpl *)impl)->getAttribute(ATTR_VALIGN);
837}
838
839void HTMLTableSectionElement::setVAlign( const DOMString &value )
840{
841 if(impl) ((ElementImpl *)impl)->setAttribute(ATTR_VALIGN, value);
842}
843
844HTMLCollection HTMLTableSectionElement::rows() const
845{
846 if(!impl) return HTMLCollection();
847 return HTMLCollection(impl, HTMLCollectionImpl::TSECTION_ROWS);
848}
849
850HTMLElement HTMLTableSectionElement::insertRow( long index )
851{
852 if(!impl) return 0;
853 int exceptioncode = 0;
854 HTMLElementImpl* ret = ((HTMLTableSectionElementImpl *)impl)->insertRow( index, exceptioncode );
855 if (exceptioncode)
856 throw DOMException(exceptioncode);
857 return ret;
858}
859
860void HTMLTableSectionElement::deleteRow( long index )
861{
862 int exceptioncode = 0;
863 if(impl)
864 ((HTMLTableSectionElementImpl *)impl)->deleteRow( index, exceptioncode );
865 if (exceptioncode)
866 throw DOMException(exceptioncode);
867}
868
DOM::DOMException
DOM operations only raise exceptions in "exceptional" circumstances, i.e., when an operation is impos...
Definition: dom_exception.h:58
DOM::DOMString
This class implements the basic string we use in the DOM.
Definition: dom_string.h:44
DOM::HTMLCollection
An HTMLCollection is a list of nodes.
Definition: html_misc.h:127
DOM::HTMLElement
All HTML element interfaces derive from this class.
Definition: html_element.h:70
DOM::HTMLTableCaptionElement
Table caption See the CAPTION element definition in HTML 4.0.
Definition: html_table.h:48
DOM::HTMLTableCaptionElement::align
DOMString align() const
Caption alignment with respect to the table.
Definition: html_table.cpp:62
DOM::HTMLTableCaptionElement::setAlign
void setAlign(const DOMString &)
see align
Definition: html_table.cpp:68
DOM::HTMLTableCellElement
The object used to represent the TH and TD elements.
Definition: html_table.h:92
DOM::HTMLTableCellElement::height
DOMString height() const
Cell height.
Definition: html_table.cpp:212
DOM::HTMLTableCellElement::setColSpan
void setColSpan(long)
see colSpan
Definition: html_table.cpp:193
DOM::HTMLTableCellElement::axis
DOMString axis() const
Names group of related headers.
Definition: html_table.cpp:143
DOM::HTMLTableCellElement::vAlign
DOMString vAlign() const
Vertical alignment of data in cell.
Definition: html_table.cpp:260
DOM::HTMLTableCellElement::chOff
DOMString chOff() const
Offset of alignment character.
Definition: html_table.cpp:176
DOM::HTMLTableCellElement::setCellIndex
void setCellIndex(long)
see cellIndex
Definition: html_table.cpp:116
DOM::HTMLTableCellElement::setHeight
void setHeight(const DOMString &)
see height
Definition: html_table.cpp:218
DOM::HTMLTableCellElement::setHeaders
void setHeaders(const DOMString &)
see headers
Definition: html_table.cpp:207
DOM::HTMLTableCellElement::setVAlign
void setVAlign(const DOMString &)
see vAlign
Definition: html_table.cpp:266
DOM::HTMLTableCellElement::setBgColor
void setBgColor(const DOMString &)
see bgColor
Definition: html_table.cpp:160
DOM::HTMLTableCellElement::setAbbr
void setAbbr(const DOMString &)
see abbr
Definition: html_table.cpp:127
DOM::HTMLTableCellElement::cellIndex
long cellIndex() const
The index of this cell in the row.
Definition: html_table.cpp:110
DOM::HTMLTableCellElement::headers
DOMString headers() const
List of id attribute values for header cells.
Definition: html_table.cpp:201
DOM::HTMLTableCellElement::setScope
void setScope(const DOMString &)
see scope
Definition: html_table.cpp:255
DOM::HTMLTableCellElement::setChOff
void setChOff(const DOMString &)
see chOff
Definition: html_table.cpp:182
DOM::HTMLTableCellElement::rowSpan
long rowSpan() const
Number of rows spanned by cell.
Definition: html_table.cpp:235
DOM::HTMLTableCellElement::ch
DOMString ch() const
Alignment character for cells in a column.
Definition: html_table.cpp:165
DOM::HTMLTableCellElement::width
DOMString width() const
Cell width.
Definition: html_table.cpp:271
DOM::HTMLTableCellElement::setNoWrap
void setNoWrap(bool)
see noWrap
Definition: html_table.cpp:229
DOM::HTMLTableCellElement::setCh
void setCh(const DOMString &)
see ch
Definition: html_table.cpp:171
DOM::HTMLTableCellElement::noWrap
bool noWrap() const
Suppress word wrapping.
Definition: html_table.cpp:223
DOM::HTMLTableCellElement::abbr
DOMString abbr() const
Abbreviation for header cells.
Definition: html_table.cpp:121
DOM::HTMLTableCellElement::align
DOMString align() const
Horizontal alignment of data in cell.
Definition: html_table.cpp:132
DOM::HTMLTableCellElement::setWidth
void setWidth(const DOMString &)
see width
Definition: html_table.cpp:277
DOM::HTMLTableCellElement::setAxis
void setAxis(const DOMString &)
see axis
Definition: html_table.cpp:149
DOM::HTMLTableCellElement::setAlign
void setAlign(const DOMString &)
see align
Definition: html_table.cpp:138
DOM::HTMLTableCellElement::setRowSpan
void setRowSpan(long)
see rowSpan
Definition: html_table.cpp:241
DOM::HTMLTableCellElement::bgColor
DOMString bgColor() const
Cell background color.
Definition: html_table.cpp:154
DOM::HTMLTableCellElement::colSpan
long colSpan() const
Number of columns spanned by cell.
Definition: html_table.cpp:187
DOM::HTMLTableCellElement::scope
DOMString scope() const
Scope covered by header cells.
Definition: html_table.cpp:249
DOM::HTMLTableColElement
Regroups the COL and COLGROUP elements.
Definition: html_table.h:323
DOM::HTMLTableColElement::width
DOMString width() const
Default column width.
Definition: html_table.cpp:377
DOM::HTMLTableColElement::setChOff
void setChOff(const DOMString &)
see chOff
Definition: html_table.cpp:347
DOM::HTMLTableColElement::setWidth
void setWidth(const DOMString &)
see width
Definition: html_table.cpp:383
DOM::HTMLTableColElement::setVAlign
void setVAlign(const DOMString &)
see vAlign
Definition: html_table.cpp:372
DOM::HTMLTableColElement::setAlign
void setAlign(const DOMString &)
see align
Definition: html_table.cpp:325
DOM::HTMLTableColElement::align
DOMString align() const
Horizontal alignment of cell data in column.
Definition: html_table.cpp:319
DOM::HTMLTableColElement::span
long span() const
Indicates the number of columns in a group or affected by a grouping.
Definition: html_table.cpp:352
DOM::HTMLTableColElement::setSpan
void setSpan(long)
see span
Definition: html_table.cpp:358
DOM::HTMLTableColElement::chOff
DOMString chOff() const
Offset of alignment character.
Definition: html_table.cpp:341
DOM::HTMLTableColElement::ch
DOMString ch() const
Alignment character for cells in a column.
Definition: html_table.cpp:330
DOM::HTMLTableColElement::vAlign
DOMString vAlign() const
Vertical alignment of cell data in column.
Definition: html_table.cpp:366
DOM::HTMLTableColElement::setCh
void setCh(const DOMString &)
see ch
Definition: html_table.cpp:336
DOM::HTMLTableElement
The create* and delete* methods on the table allow authors to construct and modify tables.
Definition: html_table.h:442
DOM::HTMLTableElement::tFoot
HTMLTableSectionElement tFoot() const
Returns the table's TFOOT , or null if none exists.
Definition: html_table.cpp:445
DOM::HTMLTableElement::deleteTFoot
void deleteTFoot()
Delete the footer from the table, if one exists.
Definition: html_table.cpp:588
DOM::HTMLTableElement::insertRow
HTMLElement insertRow(long index)
Insert a new empty row in the table.
Definition: html_table.cpp:606
DOM::HTMLTableElement::caption
HTMLTableCaptionElement caption() const
Returns the table's CAPTION , or void if none exists.
Definition: html_table.cpp:418
DOM::HTMLTableElement::createTHead
HTMLElement createTHead()
Create a table header row or return an existing one.
Definition: html_table.cpp:570
DOM::HTMLTableElement::setAlign
void setAlign(const DOMString &)
see align
Definition: html_table.cpp:477
DOM::HTMLTableElement::setBorder
void setBorder(const DOMString &)
see border
Definition: html_table.cpp:499
DOM::HTMLTableElement::setFrame
void setFrame(const DOMString &)
see frame
Definition: html_table.cpp:532
DOM::HTMLTableElement::setCellPadding
void setCellPadding(const DOMString &)
see cellPadding
Definition: html_table.cpp:510
DOM::HTMLTableElement::setSummary
void setSummary(const DOMString &)
see summary
Definition: html_table.cpp:554
DOM::HTMLTableElement::setCellSpacing
void setCellSpacing(const DOMString &)
see cellSpacing
Definition: html_table.cpp:521
DOM::HTMLTableElement::summary
DOMString summary() const
Supplementary description about the purpose or structure of a table.
Definition: html_table.cpp:548
DOM::HTMLTableElement::setRules
void setRules(const DOMString &)
see rules
Definition: html_table.cpp:543
DOM::HTMLTableElement::rows
HTMLCollection rows() const
Returns a collection of all the rows in the table, including all in THEAD , TFOOT ,...
Definition: html_table.cpp:459
DOM::HTMLTableElement::bgColor
DOMString bgColor() const
Cell background color.
Definition: html_table.cpp:482
DOM::HTMLTableElement::frame
DOMString frame() const
Specifies which external table borders to render.
Definition: html_table.cpp:526
DOM::HTMLTableElement::tBodies
HTMLCollection tBodies() const
Returns a collection of the table bodies (including implicit ones).
Definition: html_table.cpp:465
DOM::HTMLTableElement::deleteRow
void deleteRow(long index)
Delete a table row.
Definition: html_table.cpp:616
DOM::HTMLTableElement::setBgColor
void setBgColor(const DOMString &)
see bgColor
Definition: html_table.cpp:488
DOM::HTMLTableElement::cellPadding
DOMString cellPadding() const
Specifies the horizontal and vertical space between cell content and cell borders.
Definition: html_table.cpp:504
DOM::HTMLTableElement::createCaption
HTMLElement createCaption()
Create a new table caption object or return an existing one.
Definition: html_table.cpp:594
DOM::HTMLTableElement::createTFoot
HTMLElement createTFoot()
Create a table footer row or return an existing one.
Definition: html_table.cpp:582
DOM::HTMLTableElement::rules
DOMString rules() const
Specifies which internal table borders to render.
Definition: html_table.cpp:537
DOM::HTMLTableElement::setCaption
void setCaption(const HTMLTableCaptionElement &)
see caption
Definition: html_table.cpp:424
DOM::HTMLTableElement::deleteCaption
void deleteCaption()
Delete the table caption, if one exists.
Definition: html_table.cpp:600
DOM::HTMLTableElement::setTFoot
void setTFoot(const HTMLTableSectionElement &)
see tFoot
Definition: html_table.cpp:451
DOM::HTMLTableElement::width
DOMString width() const
Specifies the desired table width.
Definition: html_table.cpp:559
DOM::HTMLTableElement::tHead
HTMLTableSectionElement tHead() const
Returns the table's THEAD , or null if none exists.
Definition: html_table.cpp:431
DOM::HTMLTableElement::border
DOMString border() const
The width of the border around the table.
Definition: html_table.cpp:493
DOM::HTMLTableElement::align
DOMString align() const
Specifies the table's position with respect to the rest of the document.
Definition: html_table.cpp:471
DOM::HTMLTableElement::setTHead
void setTHead(const HTMLTableSectionElement &)
see tHead
Definition: html_table.cpp:437
DOM::HTMLTableElement::deleteTHead
void deleteTHead()
Delete the header from the table, if one exists.
Definition: html_table.cpp:576
DOM::HTMLTableElement::setWidth
void setWidth(const DOMString &)
see width
Definition: html_table.cpp:565
DOM::HTMLTableElement::cellSpacing
DOMString cellSpacing() const
Specifies the horizontal and vertical separation between cells.
Definition: html_table.cpp:515
DOM::HTMLTableRowElement
A row in a table.
Definition: html_table.h:726
DOM::HTMLTableRowElement::align
DOMString align() const
Horizontal alignment of data within cells of this row.
Definition: html_table.cpp:688
DOM::HTMLTableRowElement::ch
DOMString ch() const
Alignment character for cells in a column.
Definition: html_table.cpp:710
DOM::HTMLTableRowElement::deleteCell
void deleteCell(long index)
Delete a cell from the current row.
Definition: html_table.cpp:753
DOM::HTMLTableRowElement::setSectionRowIndex
void setSectionRowIndex(long)
see sectionRowIndex
Definition: html_table.cpp:672
DOM::HTMLTableRowElement::setCh
void setCh(const DOMString &)
see ch
Definition: html_table.cpp:716
DOM::HTMLTableRowElement::chOff
DOMString chOff() const
Offset of alignment character.
Definition: html_table.cpp:721
DOM::HTMLTableRowElement::sectionRowIndex
long sectionRowIndex() const
The index of this row, relative to the current section ( THEAD , TFOOT , or TBODY ).
Definition: html_table.cpp:666
DOM::HTMLTableRowElement::setVAlign
void setVAlign(const DOMString &)
see vAlign
Definition: html_table.cpp:738
DOM::HTMLTableRowElement::setBgColor
void setBgColor(const DOMString &)
see bgColor
Definition: html_table.cpp:705
DOM::HTMLTableRowElement::cells
HTMLCollection cells() const
The collection of cells in this row.
Definition: html_table.cpp:677
DOM::HTMLTableRowElement::vAlign
DOMString vAlign() const
Vertical alignment of data within cells of this row.
Definition: html_table.cpp:732
DOM::HTMLTableRowElement::insertCell
HTMLElement insertCell(long index)
Insert an empty TD cell into this row.
Definition: html_table.cpp:743
DOM::HTMLTableRowElement::bgColor
DOMString bgColor() const
Background color for rows.
Definition: html_table.cpp:699
DOM::HTMLTableRowElement::setAlign
void setAlign(const DOMString &)
see align
Definition: html_table.cpp:694
DOM::HTMLTableRowElement::setCells
void setCells(const HTMLCollection &)
see cells
Definition: html_table.cpp:683
DOM::HTMLTableRowElement::setChOff
void setChOff(const DOMString &)
see chOff
Definition: html_table.cpp:727
DOM::HTMLTableRowElement::rowIndex
long rowIndex() const
The index of this row, relative to the entire table.
Definition: html_table.cpp:655
DOM::HTMLTableRowElement::setRowIndex
void setRowIndex(long)
see rowIndex
Definition: html_table.cpp:661
DOM::HTMLTableSectionElement
The THEAD , TFOOT , and TBODY elements.
Definition: html_table.h:896
DOM::HTMLTableSectionElement::setCh
void setCh(const DOMString &)
see ch
Definition: html_table.cpp:817
DOM::HTMLTableSectionElement::vAlign
DOMString vAlign() const
Vertical alignment of data in cells.
Definition: html_table.cpp:833
DOM::HTMLTableSectionElement::setVAlign
void setVAlign(const DOMString &)
see vAlign
Definition: html_table.cpp:839
DOM::HTMLTableSectionElement::chOff
DOMString chOff() const
Offset of alignment character.
Definition: html_table.cpp:822
DOM::HTMLTableSectionElement::rows
HTMLCollection rows() const
The collection of rows in this table section.
Definition: html_table.cpp:844
DOM::HTMLTableSectionElement::ch
DOMString ch() const
Alignment character for cells in a column.
Definition: html_table.cpp:811
DOM::HTMLTableSectionElement::setChOff
void setChOff(const DOMString &)
see chOff
Definition: html_table.cpp:828
DOM::HTMLTableSectionElement::setAlign
void setAlign(const DOMString &)
see align
Definition: html_table.cpp:806
DOM::HTMLTableSectionElement::insertRow
HTMLElement insertRow(long index)
Insert a row into this section.
Definition: html_table.cpp:850
DOM::HTMLTableSectionElement::align
DOMString align() const
Horizontal alignment of data in cells.
Definition: html_table.cpp:800
DOM::HTMLTableSectionElement::deleteRow
void deleteRow(long index)
Delete a row from this section.
Definition: html_table.cpp:860
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.