Wordprocessing Tables
The preferred width of a single table cell is specified with the <w:tcW> element within the <tcPr> element. All widths in a table are considered preferred because widths of columns can conflict and the table layout rules can require a preference to be overridden. If this element is omitted, then the cell width is of type auto.
The preferred width for the table below (<w:tblW>) is set to auto. The first cell is set to 33.3%, as in the sample above. The samples below show the effects of varying content within the cell.
Attributes:
The attributes are:
Attribute | Description |
---|---|
w | Specifies the value of the preferred width of the cell. If omitted, the value is assumed to be zero.
Note: The 2006 version of the OOXML standard specified that the value was to be a decimal. When type="pct", the value was interpretted as fifths of a percent, so 4975=99.5%, and no % symbol was included in the attribute. In the 2011 version the value can be either a decimal or a percent, so a % symbol should be included when type="pct". |
type | Specifies the units of the width (w) property.
Possible values are:
|
Related Open Document Format (ODF) Property:
The width of a cell is set with the style:column-width attribute on the <style:table-column-properties> element for the style applied to the column for the cell. A value is a positive number.
There is also a style:rel-column-width attribute which specifies a relative width of a column. A value is a number followed by a * (U+002A, ASTERISK).
Related HTML/CSS Property:
And so it is with our own past. It is a labor in vain to attempt to recapture it: all the efforts of our intellect must prove futile. | BBB | CCC |
DDD | EEE | FFF |
GGG | HHH | III |
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA | BBB | CCC |
DDD | EEE | FFF |
GGG | HHH | III |