Reputation: 57
I need to get a list of chapters of pdf document programmatically in Objective C. I've googled, someone said that CGPDFDocumentGetCatalog may helpful but I don't know how to use it.
Upvotes: 1
Views: 481
Reputation: 1219
Use the PDFDocument class in the PDFKit Framework, something like this:
PDFDocument* pdfDoc = [[PDFDocument alloc] initWithURL:... ];
PDFOutline* pdfOutline = [pdfDoc outlineRoot];
Upvotes: 1