JVCL Help:TJvStringGrid.OnGetCellAlignment

From Project JEDI Wiki
Jump to navigationJump to search
JEDI Visual Component Library Help

Search in JVCL Help

 
Search in all projects
 

Summary

Occurs when the grid request the alignment of a cell.


Pascal

 TGetCellAlignmentEvent = procedure (Sender: TJvStringGrid; AColumn, ARow: Integer; State: TGridDrawState; var CellAlignment: TAlignment) ofobject;
propertyOnGetCellAlignment: TGetCellAlignmentEvent;


Parameters

Parameters Description
State Indicates whether the cell has input focus, whether the cell is selected, and whether the cell is a fixed (nonscrolling) cell.
CellAlignment Specifies the alignment for the cell specified by the ACol and ARow parameters. If you don't alter CellAlignment the cell is aligned as specified by Alignment.
ARow Indicates the row index of the cell that loses the input focus.
Sender The grid that has fired this event.
AColumn Indicates the column index of the cell that loses the input focus.


Description

Write an OnGetCellAlignment event handler to provide the grid with an alignment for a specific cell. Set the CellAlignment parameter to the alignment for the cell specified by the ACol and ARow parameters. CellAlignment is set to the value of property Alignment, so if you don't alter CellAlignment, the cell is aligned as specified by Alignment.
OnGetCellAlignment is fired just before the cell is drawn, or if the user calls GetCellAlignment.


See Also

TJvStringGrid.Alignment, TJvStringGrid.GetCellAlignment


About

Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page