class HTMLTableElement

# class HTMLTableElement | The create* and delete* methods on the table allow authors to construct and modify tables. More...
Full name | `DOM::HTMLTableElement`
Definition | `#include <html_table.h>`
Inherits | DOM::HTMLElement [public ]
List of all Methods
Annotated List
Files
Globals
Hierarchy
Index

#### Public Methods

- HTMLTableElement ()
- HTMLTableElement (const HTMLTableElement &other)
- HTMLTableElement (const Node &other)
- HTMLTableElement & operator = (const HTMLTableElement &other)
- HTMLTableElement & operator = (const Node &other)
- ~HTMLTableElement ()
- HTMLTableCaptionElement caption () const
- void setCaption ( const HTMLTableCaptionElement & )
- HTMLTableSectionElement tHead () const
- void setTHead ( const HTMLTableSectionElement & )
- HTMLTableSectionElement tFoot () const
- void setTFoot ( const HTMLTableSectionElement & )
- HTMLCollection rows () const
- HTMLCollection tBodies () const
- DOMString align () const
- void setAlign ( const DOMString & )
- DOMString bgColor () const
- void setBgColor ( const DOMString & )
- DOMString border () const
- void setBorder ( const DOMString & )
- DOMString cellPadding () const
- void setCellPadding ( const DOMString & )
- DOMString cellSpacing () const
- void setCellSpacing ( const DOMString & )
- DOMString frame () const
- void setFrame ( const DOMString & )
- DOMString rules () const
- void setRules ( const DOMString & )
- DOMString summary () const
- void setSummary ( const DOMString & )
- DOMString width () const
- void setWidth ( const DOMString & )
- HTMLElement createTHead ( )
- void deleteTHead ( )
- HTMLElement createTFoot ( )
- void deleteTFoot ( )
- HTMLElement createCaption ( )
- void deleteCaption ( )
- HTMLElement insertRow ( long index )
- void deleteRow ( long index )

#### Protected Methods

- HTMLTableElement (HTMLTableElementImpl *impl)

## Detailed Description

The create* and delete* methods on the table allow authors to construct and modify tables. HTML 4.0 specifies that only one of each of the `CAPTION` , `THEAD` , and `TFOOT` elements may exist in a table. Therefore, if one exists, and the createTHead() or createTFoot() method is called, the method returns the existing THead or TFoot element. See the TABLE element definition in HTML 4.0.

HTMLTableElement () | ### HTMLTableElement

HTMLTableElement (const HTMLTableElement &other) | ### HTMLTableElement

HTMLTableElement (const Node &other) | ### HTMLTableElement

HTMLTableElement (HTMLTableElementImpl *impl) | ### HTMLTableElement

[protected]

HTMLTableElement & operator = (const HTMLTableElement &other) | ### operator =

Reimplemented from HTMLElement.

HTMLTableElement & operator = (const Node &other) | ### operator =

Reimplemented from HTMLElement.

~HTMLTableElement () | ### ~HTMLTableElement

HTMLTableCaptionElement caption () | ### caption

[const]

Returns the table's `CAPTION` , or void if none exists.

void setCaption ( const HTMLTableCaptionElement & ) | ### setCaption

see caption

HTMLTableSectionElement tHead () | ### tHead

[const]

Returns the table's `THEAD` , or `null` if none exists.

void setTHead ( const HTMLTableSectionElement & ) | ### setTHead

see tHead

HTMLTableSectionElement tFoot () | ### tFoot

[const]

Returns the table's `TFOOT` , or `null` if none exists.

void setTFoot ( const HTMLTableSectionElement & ) | ### setTFoot

see tFoot

HTMLCollection rows () | ### rows

[const]

Returns a collection of all the rows in the table, including all in `THEAD` , `TFOOT` , all `TBODY` elements.

HTMLCollection tBodies () | ### tBodies

[const]

Returns a collection of the table bodies (including implicit ones).

DOMString align () | ### align

[const]

Specifies the table's position with respect to the rest of the document. See the align attribute definition in HTML 4.0. This attribute is deprecated in HTML 4.0.

void setAlign ( const DOMString & ) | ### setAlign

see align

DOMString bgColor () | ### bgColor

[const]

Cell background color. See the bgcolor attribute definition in HTML 4.0. This attribute is deprecated in HTML 4.0.

void setBgColor ( const DOMString & ) | ### setBgColor

see bgColor

DOMString border () | ### border

[const]

The width of the border around the table. See the border attribute definition in HTML 4.0.

void setBorder ( const DOMString & ) | ### setBorder

see border

DOMString cellPadding () | ### cellPadding

[const]

Specifies the horizontal and vertical space between cell content and cell borders. See the cellpadding attribute definition in HTML 4.0.

void setCellPadding ( const DOMString & ) | ### setCellPadding

see cellPadding

DOMString cellSpacing () | ### cellSpacing

[const]

Specifies the horizontal and vertical separation between cells. See the cellspacing attribute definition in HTML 4.0.

void setCellSpacing ( const DOMString & ) | ### setCellSpacing

see cellSpacing

DOMString frame () | ### frame

[const]

Specifies which external table borders to render. See the frame attribute definition in HTML 4.0.

void setFrame ( const DOMString & ) | ### setFrame

see frame

DOMString rules () | ### rules

[const]

Specifies which internal table borders to render. See the rules attribute definition in HTML 4.0.

void setRules ( const DOMString & ) | ### setRules

see rules

DOMString summary () | ### summary

[const]

Supplementary description about the purpose or structure of a table. See the summary attribute definition in HTML 4.0.

void setSummary ( const DOMString & ) | ### setSummary

see summary

DOMString width () | ### width

[const]

Specifies the desired table width. See the width attribute definition in HTML 4.0.

void setWidth ( const DOMString & ) | ### setWidth

see width

HTMLElement createTHead ( ) | ### createTHead

Create a table header row or return an existing one.

Returns: A new table header element ( `THEAD` ).

void deleteTHead ( ) | ### deleteTHead

Delete the header from the table, if one exists.

HTMLElement createTFoot ( ) | ### createTFoot

Create a table footer row or return an existing one.

Returns: A footer element ( `TFOOT` ).

void deleteTFoot ( ) | ### deleteTFoot

Delete the footer from the table, if one exists.

HTMLElement createCaption ( ) | ### createCaption

Create a new table caption object or return an existing one.

Returns: A `CAPTION` element.

void deleteCaption ( ) | ### deleteCaption

Delete the table caption, if one exists.

HTMLElement insertRow ( long index ) | ### insertRow

Insert a new empty row in the table. The new row is inserted immediately before and in the same section as the current indexth row in the table. If index is -1 or equal to the number of rows, the new row is appended. In addition, when the table is empty the row is inserted into a TBODY which is created and inserted into the table. Note. A table row cannot be empty according to HTML 4.0 Recommendation.

Parameters:

index | The row number where to insert a new row. The index starts from 0 and is relative to the logical order (not document order) of all the rows contained inside the table.

Returns: The newly created row.

void deleteRow ( long index ) | ### deleteRow

Delete a table row.

Parameters:

index | The index of the row to be deleted. This index starts from 0 and is relative to the logical order (not document order) of all the rows contained inside the table. If the index is -1 the last row in the table is deleted.

Generated by: root on macppc.ports.openbsd.org on Sat Sep 6 10:37:43 2003, using kdoc 2.0a54.