[Overview][Constants][Types][Classes][Procedures and functions][Index] Reference for unit 'ComCtrls' (#lcl)

TCustomHeaderControl.GetSectionAt

Gets the header section at the position specified in P.

Declaration

Source position: comctrls.pp line 4089

public function TCustomHeaderControl.GetSectionAt(

  P: TPoint

):Integer;

Arguments

P

  

TPoint instance with the coordinates examined in the method.

Function result

Ordinal position in Sections for the header section.

Description

GetSectionAt is an Integer function used to get the position for the header section found at the coordinates in P.

GetSectionAt iterates over the THeaderSection instances in Sections to find a matching collection item. A match is found when the X- axis coordinate in P is within the Left and Right values for the header section.

The return value contains the ordinal position in Sections where the header section is stored, or -1 if a header section was not found for the coordinates.


Version 4.0 Generated 2025-05-03 Home