Some test text!

Loading...
Guides
Migrate

Migrate to the New Viewer UI

Migrate to the New Viewer UI

If you have integrated the document viewer previously in your app (i.e. DocumentActivity or PdfViewCtrlTabHostFragment ), you can easily migrate to use the new UI with a couple of simple steps.

Prerequisites

  • Updated PDFTron libraries to version 7.1.5 (see changelog for more info)

Migrate PdfViewCtrlTabHostFragment

  1. Update all references to ViewerBuilder to ViewerBuilder2. This new builder will create the new viewer fragment PdfViewCtrlTabHostFragment2, which contains the new UI.
  2. Update all references to PdfViewCtrlTabHostFragment to PdfViewCtrlTabHostFragment2 in your project.
  3. Update all references to PdfViewCtrlTabFragment to PdfViewCtrlTabFragment2 in your project.
  4. (Optional) If you have defined the CustomAppTheme style to customize your theme, you will need to change this style to extend PDFTronAppTheme and pass it into ViewerBuilder2 as described here .

Migrate DocumentActivity

  1. Remove any calls to DocumentActivity.openDocument(...).
  2. Then launch the activity using DocumentActivity.IntentBuilder as described in this guide .
  3. If you have defined the CustomAppTheme style to customize your theme, you will need to change this style to extend PDFTronAppTheme.

Get the answers you need: Support

UPCOMING WEBINAR: Live tech update and run-through. October 21 @ 11am PDT