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

TCustomTreeView.GetHitTestInfoAt

Returns hit test results for the specified coordinates.

Declaration

Source position: comctrls.pp line 3693

public function TCustomTreeView.GetHitTestInfoAt(

  X: Integer;

  Y: Integer

):THitTests;

Arguments

X

  

Horizontal coordinate examined in the method.

Y

  

Vertical coordinate examined in the method.

Function result

Set of THitTest values for the node at the specified coordinates.

Description

GetHitTestInfoAt is a THitTests function used to gather hit test results for the coordinates specified in X and Y. The return value indicates the part(s) of a node on the tree view control beneath the given coordinates. The results are an empty set if none of the THitTest values apply to the specified position (Such as when X, Y is not within the client area for the control).

In the current implementation, the following THitTest enumeration values are used:

htOnItem
The position is over a node on the tree view control.
htOnIndent
The position is over the indent prior to a node.
htOnButton
The position is over an expand / collapse indicator for a tree node.
htOnStateIcon
The position is over the state icon for a tree node.
htOnIcon
The position is over the main icon for a tree node.
htOnLabel
The position is over the text displayed for a tree node.
htNowhere
The position is over a part of a node which does not qualify for the previous values.

The following THitTest values are not used in the current implementation: htAbove, htBelow, htOnRight, htToLeft, and htToRight.

See also

TCustomTreeView.GetNodeAtY

  

Gets the expanded tree node at the specified vertical coordinate.

TTreeNode

  

Implements a tree node displayed in a TTreeView control.

THitTests

  

Set type used to store values from the THitTest enumeration.

THitTest

  

Represents permissible results for a hit test.


Version 3.2 Generated 2024-02-25 Home