Sign in Join
FPDoc Onlineexperiment

TControl.MouseCapture property

Member of TControlprotectedIn unit Controls

True when mouse messages are currently captured by this control.

Declaration

pascal
property MouseCapture: Boolean read GetMouseCapture write SetMouseCapture;

Description

In normal operation, all mouse messages are sent to the control under the mouse pointer. Mouse messages also can be sent to a capturing control, e.g. when a control is dragged.

Applications should capture mouse events only for special purposes, and release the capture as soon as a the target position has been determined. Limited user feedback is possible while the mouse is captured, not all application controls will work properly so long.

An experiment, built from Lazarus main 2dfa93c66e of 10-22-2026. Not the official Lazarus documentation.