TCustomGrid.UpdateSelectionRange procedure
Updates the selection range when the current selection in the grid has changed.
Declaration
procedure UpdateSelectionRangeDescription
UpdateSelectionRange is a method used to update the
Selection property with the cell coordinates for the current cell
or row in the grid control. UpdateSelectionRange creates a new
TRect instance with the cell coordinates representing the current
selection in the grid.
UpdateSelectionRange uses values in ColCount, RowCount,
and Options to determine whether the rectangle represents an empty
selection, a single cell, or all cells in the current Row.
When ColCount and RowCount both contain 0 (zero), the selection range is an empty rectangle (Top, Left, Bottom, and Right members in the rectangle are -1).
When goRowSelect has been included in Options, the rectangle
contains the first non-fixed column and last column numbers for the current
Row. If row selection is not enabled in Options, the rectangle uses the values
in Col and Row to represent both the start and end cells
for the selection range.
UpdateSelectionRange is called from the ClearSelections and
FixPosition methods.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
