Vcl.Grids.TCustomGrid.DrawCellBackground
Delphi
procedure DrawCellBackground(const ARect: TRect; AColor: TColor; AState: TGridDrawState; ACol, ARow: Integer); virtual;
C++
virtual void __fastcall DrawCellBackground(const System::Types::TRect &ARect, System::Uitypes::TColor AColor, TGridDrawState AState, int ACol, int ARow);
Properties
Type | Visibility | Source | Unit | Parent |
---|---|---|---|---|
procedure function |
protected | Vcl.Grids.pas Vcl.Grids.hpp |
Vcl.Grids | TCustomGrid |
Description
Draws the background of a cell in the grid.
DrawCellBackground draws the background of a cell. Descendants of TCustomGrid can override the DrawCellBackground method to supply custom drawing techniques.
If the DefaultDrawing property is true, the background of the cell is painted before DrawCell is called, and the three-dimensional effects of the fixed cells or the focus rectangle around the focused cell is drawn after DrawCell.
The ACol and ARow parameters give the column and row indexes of the cell that should be drawn. The ARect parameter gives the boundaries of the cell in the coordinates of the canvas. The AState parameter indicates whether the cell is selected, has input focus, or is in the fixed, nonscrolling portion of the grid.