Instance Method

draw(in:forPageAt:)

Draws the portion of a print formatter’s content that goes in the given area for the specified page

Declaration

func draw(in rect: CGRect, forPageAt pageIndex: Int)

Parameters

rect

The area in which to draw the content.

pageIndex

The number of the page of content to draw.

Discussion

This method is called by the default implementation of drawPrintFormatter:forPageAtIndex: of the UIPrintPageRenderer class for each print formatter associated with a page.

See Also

Drawing the Content

func rectForPage(at: Int) -> CGRect

Returns the area enclosing a specified page of content.