PdfReaderView

open class PdfReaderView : FrameLayout, PSPDFKitViews.PSPDFView, ReflowProcessorListener

Reader View component containing a styled web view for showing the reflowed text. Reflowing means that the content will be more readable in different device sizes, without requiring a lot of zooming in and out, or scrolling. To inspect the CSS style applied to the web view please refer to the `pspdfkit/reader-view.css` file in the assets folder. This component is disabled by default and requires the reader view license to work.

See also

PdfActivityConfiguration.Builder

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)

Properties

Link copied to clipboard
Tracks visibility before the animation ends (view considered not visible when it starts to hide).

Functions

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
Checks whether PSPDFKit can show `PdfReaderView` on this device.
Link copied to clipboard
Returns the current type of this view.
Link copied to clipboard
open fun hide()
Hides the outline view (scroll up animation).
Link copied to clipboard
open fun isCanceled(): Boolean
Returns true if the reflow operation has been canceled.
Link copied to clipboard
open fun progress(currentPage: Int, totalPages: Int)
Reports the progress of the reflow operation, giving the current page that is being reflowed and the total number of pages that are being processed at the moment.
Link copied to clipboard
Unregister a previously registered listener that no longer wants to receive visibility change events.
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
open fun show()
Shows the outline view (scroll down animation).