DocumentState

class DocumentState

A state object that can be hoisted to control and observe properties of the DocumentView. Create instances of this object using rememberDocumentState.

Parameters

documentUri

The Uri for the document this state belongs to.

configuration

The PdfActivityConfiguration used for this state.

startingPage

The page to start the document in, starting from 0.

Types

Companion
Link copied to clipboard
object Companion

Functions

scrollToPage
Link copied to clipboard
suspend fun scrollToPage(@IntRange(from = 0) page: Int)

Used to scroll the DocumentView to a specific page.

Properties

configuration
Link copied to clipboard
val configuration: PdfActivityConfiguration
currentPage
Link copied to clipboard
@get:IntRange(from = 0 )
val currentPage: Int

Current page the DocumentView is on.

documentUri
Link copied to clipboard
val documentUri: Uri