Sign in Join
FPDoc Onlineexperiment

TCustomCoolBar.MouseToBandPos procedure

Member of TCustomCoolBarpublicIn unit ComCtrls

Gets the position for the band under the mouse pointer.

Declaration

pascal
procedure MouseToBandPos(X: Integer; Y: Integer; out ABand: Integer; 
 out AGrabber: Boolean)

Arguments

X

Horizontal coordinate for the mouse.

Y

Vertical coordinate for the mouse.

ABand

Position for the band under the mouse pointer, or -2147483648 when not over a band.

AGrabber

Indicates if the mouse pointer is over the grabber for the band.

Description

MouseToBandPos is a method used to get the position for the band under the specified mouse coordinates.

ABand is an Integer output parameter with the position for the band under the mouse pointer. It can contain an ordinal position in the visible bands for the control, and can be in the range 0..Bands.Count-1. The upper limit may be smaller if any of the bands have their Visible property set to False.

ABand may contain a negative value, defined in the cNewRowAbove and cNewRowBelow constants, that represent the unused space above or below the bands on the control.

ABand is set to -2147483648 (the lowest value for an Integer) if the mouse pointer is positioned over the background for the control and not one of its bands.

AGrabber is a Boolean output parameter which indicates if the mouse pointer is positioned over the grabber (or gripper) for the band in ABand.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.