[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] |
Draws the content for the cell specified in the ACol and ARow arguments.
Source position: grids.pas line 1423
protected procedure TCustomDrawGrid.DrawCell( |
aCol: Integer; |
aRow: Integer; |
aRect: TRect; |
aState: TGridDrawState |
); override; |
aCol |
|
Column number for the cell rendered in the method. |
aRow |
|
Row number for the cell rendered in the method. |
aRect |
|
Rectangle where the cell is drawn. |
aState |
|
Grid drawing state for the cell content, editor control, or borders. |
DrawCell is an overridden method in TCustomDrawGrid. It re-implements the method from the ancestor class, and does not call the inherited method. DrawCell is used to draw the content for the cell specified in the ACol and ARow arguments at the position in the ARect parameter. AState contains the grid drawing state applied to the cell.
DrawCell calls PrepareCanvas to initialize the Canvas for the control to the state in AState. This includes setting the default Color, Pen, Brush, and Font attributes used to render the cell content or editor control. The OnPrepareCanvas event handler is signalled to allow the default canvas settings to be overridden on a cell-by-cell basis.
At run-time, DefaultDrawCell is called to perform the default drawing routine for the cell when DefaultDrawing is set to True. DefaultDrawCell is always called at design-time.
At run-time, the OnDrawCell event handler is signalled (when assigned) to render the cell to the Canvas for the control using the grid draw state in the AState argument. When DefaultDrawing is False, OnDrawCell is responsible for all actions performed to draw the cell.
DrawCellGrid is called prior to exit to draw grid lines around the cell (when enabled).
DrawCell is called from the DrawRow method when it renders the visible cells in the grid row.
|
Indicates if the default drawing mechanism is used to draw the background and text for cells. |
|
|
The default method used to draw the cell at the given position using a specific state. |
|
|
Event handler signalled to draw a cell in the grid control. |
|
|
Prepares the canvas for drawing the cell at the specified location. |
|
|
Draws cell grid lines for the control. |
|
|
Draws the columns for the specified row in the grid control. |
|
|
Draws a cell using a given state at the specified grid location (Col, Row, rectangle). |
|
|
The drawing surface for the control. |
Version 4.0 | Generated 2025-05-03 | Home |