Column Widths

The following applies to all columns, including the row label columns.

Column widths are determined in several steps. Here, wid is the column widths to be determined.

1. Option COLWIDTH is defined at outset, and if COLRESIZE is 1, it can be updated by manually resizing the columns.

2. If COLAUTOFIT is 0, then COLWIDTH is the actual column width, and:

wid=. COLWIDTH * GRIDZOOM

Otherwise, If COLAUTOFIT is 1 (default), then column widths are calculated to fit the data, see Column Extents below. In this case, COLWIDTH is the minimum column width, and:

wid=. (COLWIDTH * GRIDZOOM) >. calculated column width

3. If COLSCALE is not empty, then wid is scaled to fit the actual window width available.

4. The minimum column width is then applied:

wid=. wid >. COLMINWIDTH * GRIDZOOM

5. For COLWIDTH and COLSCALE, if there are fewer values than the number of columns, the last value given is used for the remaining columns.

Column Extents

If column sizes are dynamic ( COLAUTOFIT is 1), then column extents are calculated as follows:

1. If the number of columns is unbounded, then the extents are calculated from scratch when CELLDFMT is defined, and recalculated again if a cell is changed.

2. Otherwise:

3. The calculation of column extent is the maximum extent in a column, plus the horizontal padding and twice the horizontal margin, see option GRIDMARGIN.

Row Heights

Currently, row heights are always autofit. The calculation is the same as for autofit column widths.

Grid/Sizes (last edited 2009-02-09 20:03:45 by RicSherlock)