## 27.2 Using the scope method to identify table cells

Table 27-1 lists the scope settings you can specify in the [Tables] section of the configuration file.

Table 27-1 WAI scope attributes for table cells

| [Tables] setting | Default value | [TableAccess] override | Purpose
* Cells marked as ColGroup or RowGroup via [HtmlStyles]parafmt=*Group or CellGroup marker
Column | ScopeCol | No | ScopeCol | Apply scope="col" (the default) to column-header cells
ScopeColGroup | No | ScopeColGroup | Apply scope="colgroup" to ColGroup header cells*
Row | ScopeRow | No | ScopeRow | Apply scope="row" (the default) to row-header cells
ScopeRowGroup | No | ScopeRowGroup | Apply scope="rowgroup" to RowGroup header cells*

Use these settings to identify column and row header cells that apply to more than one body column or row, either explicitly (via straddles in FrameMaker) or implicitly:

[Tables]

; ScopeCol = No (to not use) or Yes (to apply default scope="col"

; to non-empty cells in table header)

ScopeCol=No

; ScopeColGroup = No (to not use) or Yes (to apply scope="colgroup"

; instead of "col" to column head cells identified as ColGroup via

; [HtmlStyles] or the CellGroup marker col; sets ColGroupElements).

ScopeColGroup=No

; ScopeRow = No (to not use) or Yes (to apply default scope="row"

; to first non-empty cell in each row in the table)

ScopeRow=No

; ScopeRowGroup = No (to not use) or Yes (to apply scope="rowgroup"

; instead of "row" to non-empty row-spanning cells at left in table;

; applies "row" to non-spanning cells, so ScopeRow is not needed).

ScopeRowGroup=No

You can override each of these settings in the [TableAccess] section for selected tables by specifying the same setting, prefixed with No, as a property; see §27.4 Overriding default table-cell settings.

Note: If you set AccessMethod=Scope, Mif2Go automatically sets ScopeCol, ScopeRow, ScopeColGroup, and ScopeRowGroup to Yes.

Columns and rows

ScopeCol applies to non-empty cells in rows that are tagged <th> or that are designated as header rows via [Tables]TableHeaderRows or [TableAccess]HRows N.

ScopeRow applies to non-empty cells in the first (leftmost) column in the table, even if the cells in that column are tagged <td> instead of <th>; or to columns that are designated as row headers via [Tables]TableHeaderCols or [TableAccess]HCols N.

Groups of columns or rows

You can use scope=colgroup or scope=rowgroup to apply a header to all cells in a group. If you use column groups and row groups, you can specify a group scope even though none of the header cells spans more than one column or row.

For the group scope settings to be meaningful and effective, a table has to have the structure they imply. For example, scope="colgroup" works only if the table has column groups (<colgroup> elements), and scope="rowgroup" works only if the table has row groups (<tbody> elements). Therefore:

• Specifying column groups automatically sets [Tables]ColGroupElements=Yes; for more information, see §24.3.2.3 Enumerating table column groups.

• Specifying row groups automatically sets [Tables]HeadFootBodyTags=Yes; for more information, see §24.3.2.4 Wrapping table row groups.

The group scope attributes work in concert with ColGroup and RowGroup cells: header cells that are assigned [HtmlStyles] property ColGroup or RowGroup, described in §26.2.2 Using paragraph formats for table-cell attributes; or that contain marker type CellGroup, described in §26.2.4 Using custom markers for table-cell attributes.

Note: If any of your tables have footing rows, when you use scope="rowgroup" the resulting HTML might contain some surprises; see § Position table footers in §24.3.2.4 Wrapping table row groups.

| 27.1 Understanding table cell settings |  | 27.3 Using the id/headers method to identify table cells |