Contents

previewController(_:transitionImageFor:contentRect:)

Tells the delegate that the system is about to present the preview full screen or dismiss it, and asks for information to provide a smooth transition when zooming.

Declaration

optional func previewController(_ controller: QLPreviewController, transitionImageFor item: any QLPreviewItem, contentRect: UnsafeMutablePointer<CGRect>) -> UIImage?

Parameters

  • controller:

    The Qlpreviewcontroller that’s requesting the image for the preview item.

  • item:

    The item to preview or dismiss.

  • contentRect:

    The rectangle within the image that represents the document content. For icons, for example, the document content rectangle is typically smaller than the icon rectangle itself.

Return Value

A UIImage object that the preview controller cross-fades with when zooming.

Discussion

See Also

Responding to preview requests