Questions tagged [ios-pdfkit]

This tag should only be used for questions related to PDFKit which is available for iOS as of iOS 11.0 and macOS as of 10.4.

PDFKit is a framework for iOS and macOS. Display and manipulate PDF documents in your applications.

131 questions
0
votes
1 answer

PDFKit CGRect clipping to text size SwiftUI

I'm trying to have a heading where the whole top of the PDF document is filled with a color. The standard behaviour seem to be no matter how big I set the CGRect to clip to the edges of the text. let attributes = [ NSAttributedString.Key.font:…
Etienne
  • 89
  • 4
0
votes
0 answers

Performance issue with PDFAnnotation IOS PDFKIT

I'm trying to add text widgets to my pdf using IOS PDFKIT. So to achieve that goal I'm using the PDFAnnottaion class. My issue is that after adding multiples annotations (something like 15) my app is facing a big performance issue because of ram…
Michel Melhem
  • 551
  • 1
  • 8
  • 22
0
votes
0 answers

PDFKit rendering is a little blurry, but crisp on CircleCI

We have automated tests that simulate user interaction, take snapshots and compare those to previously recorded reference images. Tests that include PDF rendering (via Apple’s PDFKit) are slightly blurry on our machines but crisp on CircleCI. This…
Justin Garcia
  • 328
  • 1
  • 11
0
votes
1 answer

Possible encoding issues with PDFDocument

I am using PDFKit in a Mac app (Xcode 11.7, 10.15 deployment target) to view pdfs. Users are able to highlight selections and either copy the text, or create quotes. With some pdfs, I cannot get the correct string contents for the highlight. Take…
Giles
  • 1,428
  • 11
  • 21
0
votes
1 answer

Swift problem when adding annotations with regex to pdf page

I want to search for a regex in a pdf, and add annotations to it according, using the results from the regex. I have built a simple function that does this. As the amazing community (really amazing people who used their time helping me) posted I…
0
votes
1 answer

How to override draw method on PDFAnnotation IOS-PDFKIT

I followed another StackOverflow post that explains how i could override the draw method of a PDFAnnotation so i could draw a picture instead of a traditional PDFAnnotation. But sadly i was not able to achieve that and the annotation that is drawn…
Michel Melhem
  • 551
  • 1
  • 8
  • 22
0
votes
1 answer

How to add anotation to my pdf using objective c?

I'm fairly new to objective c and Apple's PdfKit framework and i'm unable to draw anotations on top of my pdf. I get no errors on the console. This is my code : PDFAnnotation * observation = [[PDFAnnotation alloc] init]; CGRect cgRect =…
Michel Melhem
  • 551
  • 1
  • 8
  • 22
0
votes
1 answer

Can't read PDF document using CGPDFDocumentCreateWithURL

I'm, unsuccessfully, trying to load a PDF on iOS, when debugging the code the document shows "0x0" as value. NSString *appFolderPath = [[NSBundle mainBundle] resourcePath]; NSString *pdfPath = [appFolderPath…
0
votes
1 answer

open PDF with PDFKit.PDFView on iOS

I have an application with PDF viewer, and I try to use PDFKit.PDFView which need to PDFKit.PDFDocument object. My code is: var pdfview = new PdfKit.PdfView(); var path = NSBundle.MainBundle.PathForResource("Harvard", "pdf"); var urll = new…
LofiMAM
  • 127
  • 1
  • 11
0
votes
0 answers

Remove edges and scroll from PDFView

I want to display a PDF in my macOS app using PDFKit. Therefore I've added a simple PDFView in IB. I want each slide of the PDF to be displayed separately and non intractable, just like an image. The only thing that should be possible is to walk…
Codey
  • 1,131
  • 2
  • 15
  • 34
0
votes
0 answers

PDF view not scrolling

Im am trying to learn swift and I am stuck trying to display pdf file from local url. I have set contentView which has pdfView on it. all is okay but the pdf is not scrollable. I would be happy if someone could help me. This is my code: private func…
user12723399
  • 127
  • 1
  • 1
  • 5
0
votes
0 answers

How can I set the value of an editable text field (annotation) in a pdf?

In my app users will enter information on one screen that gets put into a database. On another screen I want to display a pdf with their information used to fill out the edit text fields (annotations). In the example below the user can click "John…
Chris
  • 43
  • 2
  • 8
0
votes
1 answer

How to get the height of a paragraph using PDFKit

I am writing a pdf using iOS PDFKit. Typically I can get the height of a single text item such as a title by doing the following: return titleStringRect.origin.y + titleStringRect.size.height Where titleStringRect is the CGRect containing the…
Grant Singleton
  • 1,611
  • 6
  • 17
0
votes
1 answer

How to remove a annotation from a pdf file

I'm adding an annotation but I can't remove my added annotation. For Example: When I search 'Tubes' word it marks every 't' letter. Example Image: I only want to annotate 'tubes' word. And how can I remove all of the annotations I added. How can I…
caneraltuner
  • 263
  • 1
  • 3
  • 12
0
votes
2 answers

IOS PDFKit - Annotation content only visible when selected

I would like to fill a form in a PDF file using information users entered into my app. Using PDFKit I am using the following code which is executed after I submit the data in a textfield: for index in 0..
Sven Cozijn
  • 119
  • 14
1 2 3
8
9