Thumbnail browser
You can get previews of a document's pages.
Manipulate pages with thumbnail browser in Xamarin.Android
The ThumbnailsViewFragment class allows users to manipuate pages of a document including add, remove, re-arrange, rotate and duplicate pages. Users are also able to undo/redo page manipulations.

Show page thumbnails dialog
To show a page thumbnails dialog in your activity, create a new instance of ThumbnailsViewFragment by calling newInstance() and setting the PDFViewCtrl:
If you want to specify that the document is read-only you can use newInstance(boolean):
Export pages
If you would like to allow users to export a subset of pages from the document, you should implement OnExportThumbnailsListener interface by providing implementation for exporting pages:
If you set OnExportThumbnailsListener, the "Export" menu item will show up in the overflow menu when at least one page is selected.

Dialog callbacks
If you want to be notified when the thumbnails view dialog fragment is dismissed, implement OnThumbnailsViewDialogDismissListener interface. Also, if you want to be notified when the user attempts to edit pages while the document is read only you should implement OnThumbnailsEditAttemptWhileReadOnlyListener interface:
Manipulate pages with thumbnail browser in Xamarin.iOS
The PTThumbnailsViewController class allows users to view and navigate the pages of a PTPDFViewCtrl as well as re-arrange and remove pages.

The page thumbnails control is part of the Tools library, so make sure you have added the Tools library to your project.
Show a page thumbnails view controller
To create a new page thumbnails view controller instance and display it from another view controller, supply a PTPDFViewCtrl instance to the PTThumbnailsViewController designated initializer:
Populate the view controller with thumbnail images
The thumbnail images shown in the thumbnails view controller are generated by the GetThumbAsync: method of the PTPDFViewCtrl class. When ready, the thumbnail images are provided to the pdfviewCtrl's delegate via the GotThumbAsync:thumbImage: method.
In your class adopting the PTPDFViewCtrlDelegate protocol (usually the same view controller presenting the thumbnails view controller), add the following:
Interact with the view controller
Pages can be re-arranged and removed in edit-mode, which is activated by the 'Edit' button in the navigation bar. Long-pressing and dragging allows the user to move a page to a different location in the same document, and tapping one or more documents selects them for removal with the trash can icon. The user is prompted for confirmation before any pages are permanently removed.
Last updated
Was this helpful?