Some test text!

Search
Hamburger Icon

Xamarin / Guides / Migrate

Migrate to the New Viewer UI

Migrate to the New Viewer UI in Xamarin.Android

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 Apryse libraries to version 8.0.0 (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: Chat with us