GoToPagePoint

Viewer interaction

Description

Jumps to the given page and scrolls so the given point of that page lands at the top-left of the viewport, so link destinations and search hits can be brought precisely into view

The point is given in top-down page user-space coordinates, mapped through the current view rotation and zoom, the current page is recomputed from the final scroll position, the scroll handlers are notified and the view repaints

Syntax

Delphi

Function TPDFlibViewer.GoToPagePoint(NewPage: Integer; XPt, YPt: Double): Integer;

Parameters

NewPageRequested one-based page index, clamped through GoToPage
XPt, YPtPoint in top-down page user-space coordinates that should land at the viewport top-left

Return values

0No page could be shown
Positive valueThe page now shown

See also

TPDFlibViewer, GoToPage, ClientPointToPage, GetScrollPosForPage