DocumentID: ECMA-376/Part4/2.6.4 Title: ECMA-376, Part4: 2.6.4 cols (Column Definitions) Extracted-From: ECMA-376 Office Open XML File Formats, 1st Edition / December 2006 Warning: Coverted to HTML format by a script known to have bugs
This element specifies the set of columns defined for this section in the document.
[Example: Consider a document in which a section defines two columns of 4.16" and 1.83", respectively, resulting in the following WordprocessingML:
<w:cols w:equalWidth="0">
<w:col w:w="2640" w:space="720"/>
<w:col w:w="6000"/>
</w:cols>
The cols element defines the set of columns defined for this section, which because equalWidth is 0, are defined by the number of col elements contained in the column definition. In this case, the first column is 2,640 twentieths of a point wide (as 2640/1440ths of an inch equals 1.83 inches) with one-half of an inch space after, and the second column is 6,000 twentieths of a point wide (4.16 inches). end example]
Based on the presence of the equalWidth attribute, a consumer shall render the columns using:
equalWidth is true, then the columns are defined using the data stored as attributes of the cols element (defined below).equalWidth is false, then the columns are defined using the presence and data on each child col element (§2.6.3).|
Parent Elements |
|
Child Elements |
Subclause |
|---|---|
|
col (Single Column Definition) |
|
Attributes |
Description |
|---|---|
|
equalWidth (Equal Column Widths) |
Specifies whether all text columns in the current section are of equal width. If this attribute is present and its value is set to true, on, or 1, then all columns for this text section are of an equal width and are calculated as follows:
If this attribute is present and its value is set to false, off, or 0, then all columns for this text section are of different widths and are defined by each col element as follows:
[Example: Consider a section with column information defined as follows:
This set of columns has a The possible values for this attribute are defined by the ST_OnOff simple type (§2.18.67). |
|
num (Number of Equal Width Columns) |
Specifies the number of text columns in the current section. If all columns are not of equal width (the [Example: Consider a section with column information defined as follows:
This set of columns has a The possible values for this attribute are defined by the ST_DecimalNumber simple type (§2.18.16). |
|
sep (Draw Line Between Columns) |
Specifies if a vertical line is drawn between each of the text columns in this section. If set to true, on, or 1, then a vertical line shall be drawn in the center of the spacing between each column in this section. [Example: Consider a section with column information defined as follows:
This set of columns has a The possible values for this attribute are defined by the ST_OnOff simple type (§2.18.67). |
|
space (Spacing Between Equal Width Columns) |
Specifies the spacing between text columns in the current section. If all columns are not of equal width (the [Example: Consider a section with column information defined as follows:
This set of columns has a The possible values for this attribute are defined by the ST_TwipsMeasure simple type (§2.18.105). |
The following XML Schema fragment defines the contents of this element:
<complexType name="CT_Columns">
<sequence minOccurs="0">
<element name="col" type="CT_Column" maxOccurs="45"/>
</sequence>
<attribute name="equalWidth" type="ST_OnOff" use="optional"/>
<attribute name="space" type="ST_TwipsMeasure" use="optional"/>
<attribute name="num" type="ST_DecimalNumber" use="optional"/>
<attribute name="sep" type="ST_OnOff" use="optional"/>
</complexType>