Pdf Thumbnail Grid
open class PdfThumbnailGrid : RelativeLayout, PSPDFKitViews.PSPDFView, DocumentListener, PdfDrawableManager, OnFileWriteCompleteListener
Scrollable grid view of document pages.
Types
Link copied to clipboard
interface OnDocumentSavedListener
Listener for document saving inside PdfThumbnailGrid.
Link copied to clipboard
interface OnPageClickListener
Listener for observing a PdfThumbnailGrid page click.
Properties
Link copied to clipboard
View background color.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Thumbnail Grid item label text style.
Functions
Link copied to clipboard
Adds a PdfDrawableProvider to be managed by this object.
Link copied to clipboard
open fun addOnDocumentSavedListener(onDocumentSavedListener: PdfThumbnailGrid.OnDocumentSavedListener)
Adds a listener that will be notified about document saves inside the thumbnail grid.
Link copied to clipboard
Adds a listener that will be notified when a page on the ThumbnailGrid was clicked.
Link copied to clipboard
Register a
listener
that would like to receive visibility change events.Link copied to clipboard
Called by the activity when the view should unbind the previously set document.
Link copied to clipboard
Enters document editing mode.
Link copied to clipboard
Exits document editing mode.
Link copied to clipboard
Link copied to clipboard
Returns The default NewPageDialog.Callback that is used by default by the .
Link copied to clipboard
Returns document editor to perform operations such as page manipulation, reordering and importing documents.
Link copied to clipboard
Returns the thumbnail grid background label background.
Link copied to clipboard
Returns the current type of this view.
Link copied to clipboard
Retrieves the currently selected pages of the thumbnail grid.
Link copied to clipboard
Link copied to clipboard
Returns
true
if page labels are shown, false
otherwise.Link copied to clipboard
Called when the user taps / clicks on the document, not the page itself but on the side (if visible).
Link copied to clipboard
Called when saving a document or exporting pages to a given destination is complete.
Link copied to clipboard
Called when document is successfully loaded and the document view has been laid out.
Link copied to clipboard
Called if document loading has failed.
Link copied to clipboard
open fun onDocumentSave(@NonNull document: PdfDocument, @NonNull saveOptions: DocumentSaveOptions): Boolean
Called before document will be saved.
Link copied to clipboard
Called if document saving has been cancelled.
Link copied to clipboard
Called when saving a document in place is complete.
Called after the document has been saved.
Link copied to clipboard
Called if document saving has failed.
Link copied to clipboard
open fun onDocumentZoomed(@NonNull document: PdfDocument, @IntRange(from = 0 ) pageIndex: Int, scaleFactor: Float)
Called when a user zooms a document.
Link copied to clipboard
Called when user scrolled to a new page.
Link copied to clipboard
open fun onPageClick(@NonNull document: PdfDocument, @IntRange(from = 0 ) pageIndex: Int, @Nullable event: MotionEvent, @Nullable pagePosition: PointF, @Nullable clickedAnnotation: Annotation): Boolean
Called when user taps / clicks on the page.
Link copied to clipboard
Called when content of page with pageIndex has changed (for example due to annotation or form field being updated).
Link copied to clipboard
Removes a previously added PdfDrawableProvider.
Link copied to clipboard
open fun removeOnDocumentSavedListener(@Nullable onDocumentSavedListener: PdfThumbnailGrid.OnDocumentSavedListener): Boolean
Removes a listener from the list of registered onDocumentSaved listeners
open fun removeOnDocumentSavedListener(onPageClickListener: PdfThumbnailGrid.OnPageClickListener): Boolean
Removes a listener from the list of registered onPageClick listeners
Link copied to clipboard
Unregister a previously registered
listener
that no longer wants to receive visibility change events.Link copied to clipboard
Called when the
document
has been loaded and is going to be displayed.Link copied to clipboard
Enables/Disables document editor.
Link copied to clipboard
Enables/Disables document editor "Export pages" option in action bar.
Link copied to clipboard
Enables/Disables document editor "Save As" option in action bar.
Link copied to clipboard
Sets the thumbnail grid background label background.
Link copied to clipboard
Sets a NewPageFactory that will be used by the document editor.
Link copied to clipboard
open fun setOnPageClickListener(@Nullable onPageClickListener: PdfThumbnailGrid.OnPageClickListener)
Sets the OnPageClickListener, replacing any previously set listener.
Link copied to clipboard
Sets whether the page labels will be shown or just the page number.