RegionAtClientPoint

Viewer interaction

Description

Identifies the link, non-link annotation or form field under a Viewer client coordinate

The returned record includes the one-based page and top-down PDF point coordinate after accounting for zoom, scrolling, page layout and view rotation

Syntax

Delphi

Function TPDFlibViewer.RegionAtClientPoint(X, Y: Integer; Out Region: TPDFlibViewerActiveRegion): Boolean;

Parameters

X, YPoint in the control's client area, in pixels
RegionReceives the region found. Kind is vrFormField, vrLink or vrAnnotation, Index the one-based form field or annotation index, and Subtype the annotation subtype name or Widget for a form field. Page, XPt and YPt are filled whenever the point lies on a page, also when no interactive region is found there. A form field is reported in preference to an annotation at the same point

Return values

FalseThe point is outside an interactive region; Region.Kind is vrNone
TrueA link, annotation or form field was found