PSPDFKit for iOS Adds OCR

Just a few short weeks after our packed 9.4 release, we’re now following up with PSPDFKit 9.5 for iOS! In this release, we’re shipping another major new framework component: optical character recognition (OCR). With OCR, you’ll be able to extend PSPDFKit’s extensive support for PDF text processing to an even larger set of previously inaccessible PDF documents. Along with the release of OCR, we’re also excited to be shipping our revamped touch handling and a few initial fixes and improvements for iOS 14 and macOS 11.

OCR

When working with PDFs, you might encounter documents that contain pages without accessible text. This is especially common when dealing with scanned documents or documents that contain photographed pages. With our new OCR component, you can enhance those raster and vector PDFs to give you interactive text, thereby unlocking powerful PDF text functionality such as text markup annotations, text selection, text extraction, and search.

To learn more about the OCR component and all the PSPDFKit platforms supporting it, please see our dedicated component announcement blog post.

On iOS, we’re distributing OCR as a new optional framework with customizable language packs. Check out our OCR guide section to learn how to integrate the framework and use the API it offers.

OCR is a new component that can be added to your license. Please reach out to us if you’re interested in adding it to your license, if you want to learn more about the roadmap for OCR, or if you want to provide feedback and feature requests related to your use case.

Touch Handling

Over the years, we’ve received a lot of support requests about customizing the built-in touch interactions in our main document viewer and about adding custom interactions. While we did offer some delegate calls and subclassing hooks to enable certain customization requests, it was often tricky to hook into our touch handling without disabling built-in interactions or having to redo them. Additionally, the complexity of this code not only affected customization options, but also limited what we could do to push the built-in functionality to the next level, especially with the new interactions made possible by the iPad cursor and Mac Catalyst.

To resolve this issue, we decided to rewrite our touch handling from the ground up. We did this by adopting a modern architecture based on multiple UIInteractions and single-purpose gesture recognizers with cleanly modeled priorities and failure requirements. We also designed a whole new public API layer that makes it extremely easy to hook into the built-in functionality of touch interactions and achieve all previously possible customizations, as well as many new ones.

If you previously had to customize touch handling by subclassing PageView, or if you had to disable and reimplement built-in behaviors, there’s a good chance you can now achieve your customizations in a simpler and more robust manner. We’ve written a migration guide to get you started. It showcases some common customization use cases and code snippets to illustrate the power of this new API.

iOS 14 and macOS Big Sur

We’re already hard at work getting PSPDFKit ready for iOS 14 and macOS Big Sur. We plan on releasing a fully compatible version with new features and full Xcode 12 support later this year alongside Xcode 12 GM. We’ll also be offering nightly access to preliminary Xcode 12 builds to help everybody quickly adapt their apps to the new system versions and the new macOS architecture.

In the meantime, we’ve already been able make some preliminary improvements and fixes available in this version of PSPDFKit. PSPDFKit 9.5 for iOS improves compatibility with Mac Catalyst on macOS Big Sur by enabling the previously problematic Document Editor drag and drop and fixing some other smaller issues. We also adopted settings from assistive technologies in SpeechController to honor the new custom speech settings on iOS 14 and macOS Big Sur.

More Details

In addition to the two main features outlined above, this release also improves memory handling for the Office file conversion operation, improves touch handling for custom scrubber bar buttons, and fixes several other smaller issues.

To see a complete list of changes, check out the PSPDFKit 9.5 for iOS changelog.

PSPDFKit for iOS

Download the free 60-day trial and add it to your app today.