OnDrawBackground
Event called while the background of cell within the column is being painted and doCustom
is included in DrawingOptions
property.
pas
property OnDrawBackground: TNxDrawCellEvent read FOnDrawBackground write FOnDrawBackground;
Example
pas
procedure TForm1.ButtonColumnDrawBackground(Sender: TObject; ACol, ARow: Integer; CellRect: TRect; State: TNxCellPaintingState); begin with NextGrid61.Canvas do begin Brush.Color := clBtnFace; FillRect(CellRect); if csPressed in State then Frame3D(NextGrid61.Canvas, CellRect, clBtnShadow, clBtnHighlight, 1) else Frame3D(NextGrid61.Canvas, CellRect, clBtnHighlight, clBtnShadow, 1); end; end;