We are pleased to introduce version 6.10.0 of PDFTron's iOS SDK . This release adds a universal document viewing API, file comparison API, and more .

Universal document viewing

With this release, it is now easier than ever to support PDFs and other document formats in your own project with the ability to open and display a wide variety of different file formats with the same API. The PTDocumentViewController and PTTabbedDocumentViewController classes can now open PDF, Microsoft Office (Word, Powerpoint, Excel), iWork (Pages, Keynote, Numbers), image, markdown, and many more types of documents.

All of this is possible with the incredibly powerful openDocument(with:) API:

// Open a PDF, .docx, .pptx, .xlsx, .doc, and many more types of documents.
documentViewController.openDocument(with: documentURL)

The document can be located locally on the device or remotely and downloaded by the viewer as necessary. For more information, please see our guide on showing documents.

The following is an example of the support for Office documents in the PTDocumentViewController class via the openDocument(with:) API, using a sample Word document found here:

Viewing office documents
Viewing a Word document in a PTDocumentViewController.

File comparison API

This release also introduces a powerful file comparison API to easily spot differences between different revisions of a document. The resolution independent file comparison offers the same functionality available on the PDFTron Android and Web SDKs. An interactive demo of this feature can be found here.

An example of this feature can also be seen in the following, where the differences between revisions are highlighted in red:

Revision 1Revision 2Difference
Revision 1Revision 2Difference

And more…

Please see our change log for a list of all changes.

We hope you like these changes and any feedback is greatly appreciated. Please don't hesitate to contact us if you have any questions or suggestions. We also have many exciting new features planned for the coming weeks and months, so stay tuned.