Vcl.DBGrids.TCustomDBGrid.CalcTitleRect

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

function CalcTitleRect(Col: TColumn; ARow: Integer;
var MasterCol: TColumn): TRect;

C++

System::Types::TRect __fastcall CalcTitleRect(TColumn* Col, int ARow, TColumn* &MasterCol);

Properties

Type Visibility Source Unit Parent
function protected
Vcl.DbGrids.pas
Vcl.DBGrids.hpp
Vcl.DBGrids TCustomDBGrid

Description

Calculates the rectangular region that covers the cell indicated by the column and row parameters.

In ADT datasets with ObjectView set to true, the rectangle covering a cell may be larger than the cell itself, covering several cells. The MasterCol parameter returns the DBGrid column object that determines the drawing behaviors of the calculated rectangle. For example, if the column parameter is an ADT child field, MasterCol will point to the column containing the ADT child field's parent field, or grandparent, depending on the Row param. Row 0 would return the outermost parent of the ADT child, and would return a rectangle that spans all of the ADT children of that parent. If the current column is not an ADT child, MasterCol returns nil (Delphi) or NULL (C++).

See Also