Creates a named destination point in the current PDF page.
SDKs
- iOS 10.0+
- Mac Catalyst 13.0+
- tvOS 10.0+
Framework
- UIKit
Declaration
Parameters
name
The name of the destination, used as a reference by the
set
method.Destination With Name(_: for:) point
The location of the destination point, in the PDF coordinate space.
Discussion
Use this method in conjunction with the set
method to create internal links within a PDF. This method represents the creation of the points to which the PDF viewer will jump when a user clicks a link.
Note
Specify the point
value in the PDF coordinate space, not the Core Graphics context coordinate space. This means that the origin is in the bottom-left corner of the context rather than the top-left, and the y-axis increases in an upwards direction. Use the user
property on CGContext
to map between the two.
For an example of how to use internal links, including mapping between coordinate spaces, see Creating Internal Links in UIGraphics
.