Questions tagged [uiprintpagerenderer]

A UIPrintPageRenderer object draws pages of content that are to be printed, with or without the assistance of print formatters. Available in iOS 4.2 and later . The issues related with coco touch's UIPrintPageRender should only use this tag.

A page renderer is an instance of a custom subclass of UIPrintPageRenderer. When you compose a print job using the shared instance of UIPrintInteractionController, you assign the page renderer to the printPageRenderer property of that instance.

UIPrintPageRenderer usually requires you to specify the number of pages of printable content by overriding numberOfPages. It also allows you to specify the heights of page headers and footers.

Source: UIPrintPageRenderer Class Reference

Related tag:

38 questions
0
votes
1 answer

UIPrintPageRenderer is different size on iPad

I am using viewPrintFormatter() from a WKWebView to print some HTML. I have a CustomPrintPageRenderer which is a subclass of UIPrintPageRenderer which sets it's paperRect and printableRect to 595.2x841.8 and footer to 50. I call this code to…
Darren
  • 10,182
  • 20
  • 95
  • 162
0
votes
1 answer

swift UIPrintPageRenderer printableRect.size.width is always zero (0)

I'm using a UIActivityViewController to print (amongst other activities). So I pass it an instance of my custom subclass of UIPrintPageRenderer, for which the relevant code is below. In essence, I want to print two multi-line attributed strings,…
Son of a Beach
  • 1,733
  • 1
  • 11
  • 29
0
votes
0 answers

Lazy rendering print pages on iOS

I need to print custom UI in a cross-platform application. On Windows, the work flow is like: Choose what to print Open the Windows Print dialog/print preview. This only queries for print pages as they are needed. Begin printing and report progress…
J Nelson
  • 138
  • 1
  • 1
  • 12
0
votes
1 answer

UIGraphicsBeginPDFContextToData does not show image after pdf creation

I am working on the HtmltoPDF creation. It is working fine when some image URL but not working with my server image URL. Working URL downloaded from the google Issue in the server image URL I have put here my code for the pdf generation. Please…
Ilesh P
  • 3,940
  • 1
  • 24
  • 49
0
votes
1 answer

UIPrintPageRenderer and UIViewPrintFormatter

Anyone able to use these APIs? I would like to know if using these APIs will make your app rejected in App Store review? I found this answer from other thread its from 2015 so I'm not sure if still the case 'til now.
SquareBox
  • 823
  • 1
  • 10
  • 22
0
votes
1 answer

What image size need to print a full A4 paper with UIPrintInteractionController?

Printing logic look like this: let printController = UIPrintInteractionController.shared printController.printInfo = printInfo printController.showsNumberOfCopies = false printController.printingItem = image printController.present(animated: true,…
0
votes
1 answer

NSInteger to const char *

I am handed a (NSInteger) pageIndex and need to print that on a page with void CGContextShowTextAtPoint ( CGContextRef c, CGFloat x, CGFloat y, const char *string, size_t length ); how do I get the const char *string and not to forget…
vanHoesel
  • 956
  • 9
  • 22
0
votes
1 answer

UIPrintPageRenderer paperRect always returns 0x0

I've set up printing within my iOS app and it works fine. However, I'm generating my document based on a user preference for the page size. I would expect that I could detect the page size from the printer system and use that instead. The paperRect…
arlomedia
  • 8,534
  • 5
  • 60
  • 108
1 2
3