Allow Table Columns To Exceed Preferred Widths of Constituent Cells. When the object is serialized out as xml, its qualified name is w:autofitToFirstFixedWidthCell.
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)
[ISO/IEC 29500-1 1st Edition]
autofitToFirstFixedWidthCell (Allow Table Columns To Exceed Preferred Widths of Constituent Cells)
This element specifies that when performing an AutoFit on a table in a WordprocessingML document in order to display it, applications shall alter that logic slightly in order to mimic the behavior of a previous word processing application.
Normally, the AutoFit behavior of a table is as is described in the associated simple type. This element, when present with a val attribute value of true (or equivalent), specifies that this logic shall be changed as follows:
If the width of a grid column in a table has been set by a preferred table cell width, then that column's width can be enlarged by the content of cells which themselves do not have a preferred width (in contrast, the normal logic never allows the content of cells to override a preferred width on a grid column).
[Example: Consider a WordprocessingML table with only one preferred cell width, a width of 720 points on the second cell in the first column, as follows:
<w:tbl> … <w:tr> <w:tc> <w:p/> </w:tc> <w:tc> <w:p/> </w:tc> </w:tr> <w:tr> <w:tc> <w:tcPr> <w:tcW w:w="720" w:type="dxa" /> </w:tcPr> <w:p/> </w:tc> <w:tc> <w:p/> </w:tc> </w:tr> </w:tbl>
The default presentation would have the first column constrained to 720 points by the preferred width of the second cell in the first column:
However, if this compatibility setting is turned on:
<w:compat> <w:autofitToFirstFixedWidthCell /> </w:compat>
Then the column would be resized proportionally based on the content (ignoring the preferred width in that row), resulting in the following output:
compat (Part 1, §126.96.36.199)
This element’s content model is defined by the common boolean property definition in Part 1, §17.17.4.
© ISO/IEC29500: 2008.