Class DocumentState
-
- All Implemented Interfaces:
-
com.pspdfkit.listeners.OnVisibilityChangedListener
public abstract class DocumentState implements OnVisibilityChangedListener
A state object that can be hoisted to control and observe properties of the com.pspdfkit.jetpack.compose.views.DocumentView. Create instances of this object using rememberDocumentState.
-
-
Field Summary
Fields Modifier and Type Field Description private final StateFlow<Boolean>
viewWithOverlappingToolbarShown
private DocumentConnection
documentConnection
-
Method Summary
Modifier and Type Method Description final StateFlow<Boolean>
getViewWithOverlappingToolbarShown()
Keep track of whether a full screen view is shown that is not the document view so we can handle the main toolbar clipping final DocumentConnection
getDocumentConnection()
Provides ability to perform specific tasks in Document. final Unit
setDocumentConnection(DocumentConnection documentConnection)
Provides ability to perform specific tasks in Document. abstract String
getTitle()
Provides the title of the document. final Unit
toggleView(Integer option)
Toggles the view based on the provided MENU_OPTIONS in com.pspdfkit.ui.PdfActivity. Unit
onShow(View view)
Called whenever a PSPDFKit view has become visible. Unit
onHide(View view)
Called whenever a PSPDFKit view has been hidden. -
-
Method Detail
-
getViewWithOverlappingToolbarShown
final StateFlow<Boolean> getViewWithOverlappingToolbarShown()
Keep track of whether a full screen view is shown that is not the document view so we can handle the main toolbar clipping
-
getDocumentConnection
final DocumentConnection getDocumentConnection()
Provides ability to perform specific tasks in Document.
-
setDocumentConnection
final Unit setDocumentConnection(DocumentConnection documentConnection)
Provides ability to perform specific tasks in Document.
-
toggleView
final Unit toggleView(Integer option)
Toggles the view based on the provided MENU_OPTIONS in com.pspdfkit.ui.PdfActivity.
- Parameters:
option
- The menu id of view to toggle.
-
-
-
-