PdfThumbnailBar

Bar showing thumbnails of pages for quick selection. This class is basically a wrapper view around the actual thumbnail bar implementations, like PdfStaticThumbnailBar and . It will handle all the logic for thumbnail bar implementations so it's recommended that you use it directly, if adding thumbnail bar as a component to your custom layout. To select the thumbnail bar mode/style, use setThumbnailBarMode method.

Constructors

Link copied to clipboard
constructor(@NonNull context: Context)
constructor(@NonNull context: Context, @Nullable attrs: AttributeSet)
constructor(@NonNull context: Context, @Nullable attrs: AttributeSet, defStyleAttr: Int)
constructor(@NonNull context: Context, @Nullable attrs: AttributeSet, defStyleAttr: Int, defStyleRes: Int)

Types

Link copied to clipboard
class ConvertToDrawable : Function<T, R>
Reactive function that converts a Bitmap to a Drawable with fade effect if needed.
Link copied to clipboard
Listener for receiving page changes caused by the user touching or dragging the .

Functions

Link copied to clipboard
open fun addDrawableProvider(@NonNull drawableProvider: PdfDrawableProvider)
Adds a PdfDrawableProvider to be managed by this object.
Link copied to clipboard
Register a listener that would like to receive visibility change events.
Link copied to clipboard
open fun clearDocument()
Called by the activity when the view should unbind the previously set document.
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Returns the current type of this view.
Link copied to clipboard
Returns the border color for the selected thumbnail in the thumbnail bar.
Link copied to clipboard
Returns the border color for the thumbnails in the thumbnail bar.
Link copied to clipboard
@IntRange(from = 1)
open fun getThumbnailHeight(): Int
Returns the height of the thumbnails in thumbnail bar.
Link copied to clipboard
@IntRange(from = 1)
open fun getThumbnailWidth(): Int
Returns the width of the thumbnails in thumbnail bar.
Link copied to clipboard
open fun hide()
No-op for PdfThumbnailBar.
Link copied to clipboard
Link copied to clipboard
open fun isDisplayed(): Boolean
Called when the activity needs to know the visibility of this view.
Link copied to clipboard
Returns whether the redaction annotation preview mode is enabled or not.
Link copied to clipboard
open fun removeDrawableProvider(@NonNull drawableProvider: PdfDrawableProvider)
Removes a previously added PdfDrawableProvider.
Link copied to clipboard
Unregister a previously registered listener that no longer wants to receive visibility change events.
Link copied to clipboard
open fun setBackgroundColor(@ColorInt backgroundColor: Int)
Sets the background color for the thumbnail bar.
Link copied to clipboard
open fun setDocument(@NonNull document: PdfDocument, @NonNull configuration: PdfConfiguration)
Called when the document has been loaded and is going to be displayed.
Link copied to clipboard
Register a listener that is notified whenever the user changed the page on the thumbnail bar.
Link copied to clipboard
Enables or disables redaction annotation preview mode.
Link copied to clipboard
Sets the border color for the selected thumbnail in the thumbnail bar.
Link copied to clipboard
open fun setThumbnailBarMode(@NonNull thumbnailBarMode: ThumbnailBarMode)
Sets thumbnail bar mode whether static or scrollable.
Link copied to clipboard
open fun setThumbnailBorderColor(@ColorInt borderColor: Int)
Sets the border color for the thumbnails in the thumbnail bar.
Link copied to clipboard
open fun setThumbnailHeight(@IntRange(from = 1) thumbnailHeight: Int)
Sets the height of the thumbnails in thumbnail bar.
Link copied to clipboard
open fun setThumbnailWidth(@IntRange(from = 1) thumbnailWidth: Int)
Sets the width of the thumbnails in thumbnail bar.
Link copied to clipboard
open fun show()
No-op for PdfThumbnailBar.