Wt::WTableCell Class Reference

A container widget that represents a cell in a table. More...

#include <Wt/WTableCell>

Inheritance diagram for Wt::WTableCell:

Inheritance graph
[legend]

List of all members.

Public Member Functions

void setRowSpan (int rowSpan)
 Set the row span.
int rowSpan () const
 Get the row span.
void setColumnSpan (int colSpan)
 Set the column span.
int columnSpan () const
 Get the column span.
void setContentAlignment (int contentAlignment)
 Set the horizontal and vertical content alignment.
int contentAlignment () const
 Get the content alignment.
int row () const
 get the row index of this cell.
int column () const
 get the column index of this cell.
WTabletable () const
 get the table to which this cell belongs.


Detailed Description

A container widget that represents a cell in a table.

A WTable provides a grid of WTableCell widgets. The contents of each cell is accessed through a WTableCell. A WtableCell may overspan more than one grid item, by specifying a rowSpan and columnSpan . WTableCells at overspanned positions are hidden.

A WTableCell acts as any other WContainerWidget, except that both the vertical and horizontal alignment of contents may be specified with setContentAlignment(int contentAlignment).

The inline property of a WTableCell is not used.

See also:
WTable::elementAt(int row, int column)

Member Function Documentation

void Wt::WTableCell::setRowSpan ( int  rowSpan  ) 

Set the row span.

The row span indicates how many table rows this WTableCell overspans. By default, a WTableCell has a row span of 1, only occupying its own grid cell. A row span greater than 1 indicates that table cells to the right of this one are overspanned.

int Wt::WTableCell::rowSpan (  )  const [inline]

Get the row span.

See also:
setRowSpan(int rowSpan)

void Wt::WTableCell::setColumnSpan ( int  colSpan  ) 

Set the column span.

The column span indicates how many table columns this WTableCell overspans. By default, a WTableCell has a column span of 1, only occupying its own grid cell. A column span greater than 1 indicates that table cells below this one are overspanned.

int Wt::WTableCell::columnSpan (  )  const [inline]

Get the column span.

See also:
setColumnSpan(int colSpan)

void Wt::WTableCell::setContentAlignment ( int  contentAlignment  ) 

Set the horizontal and vertical content alignment.

Set the horizontal and vertical content alignment, as the logical OR'ed value of WWidget::VerticalAlignment and WContainerWidget::HorizontalAlignment. The default alignment is (AlignTop | AlignLeft ).

int Wt::WTableCell::contentAlignment (  )  const

Get the content alignment.

See also:
setContentAlignment(int contentAlignment)

Reimplemented from Wt::WContainerWidget.


Generated on Fri Sep 12 17:01:15 2008 for Wt by doxygen 1.5.6