TCustomGrid.DefaultDrawing property
Indicates if the default drawing mechanism is used to draw the background and text for cells.
Declaration
property DefaultDrawing: Boolean read FDefaultDrawing write SetDefaultDrawing default True;Description
DefaultDrawing is a
Boolean property which indicates if
the default drawing mechanism is used to draw the background and text for the
cells on the grid control. The default value for the property is
True.
Normally, the grid prepares its canvas using the properties needed for the
kind cell type that is being painted. DefaultDrawing indicates that the grid
control handles drawing the background and text for the cell (including a
visible cell Editor) using the relevant properties.
Use the OnDrawCell event handler to handle drawing a cell using an
appearance different than the default provided in PrepareCanvas. When
DefaultDrawing is set to False, the OnDrawCell event handler is
responsible for both the background and text content in the cell.
Changing the value for the property causes the Invalidate method
to be called to redraw the control.
DefaultDrawing is used in the PrepareCanvas method to configure the control Canvas for a drawing operation. It is also used in the DrawCell method in descendent classes.
See also
An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.
