PdfView
Displays every page in document as a vertically scrolling Compose view.
The caller retains ownership of document. PdfView closes temporary rendered bitmaps, but never closes the document itself.
onLinkClick runs before the built-in link behavior. Return true to consume the link. Returning false lets PdfView navigate internal destinations. By default, URI links open through the platform URI handler. Pass null to onUriLinkClick to ignore them, or provide a callback to replace the default behavior. Link activation failures are reported through onLinkError, separately from page loading and rendering failures.
Set pageBorder to null to render pages without a border. pageLoadingContent is shown while page information or imagery is loading. pageErrorContent receives the original failure; when it is null, PdfView displays its built-in error message.
Parameters
The open PDF document to display. The caller remains responsible for closing it.
The modifier applied to the PDF viewport.
The state that controls scrolling, zoom, and rendered-page caching.
The vertical space between adjacent pages.
The padding around the page list.
The background color shown behind each rendered page.
The maximum width or height, in pixels, of a rendered page bitmap.
Called when page information or page rendering fails.
Called before built-in link handling. Return true to consume the link.
The border drawn around each page, or null for no border.
Content displayed while a page is loading.
Content displayed when a page fails to load or render. When null, the built-in error content is used.
Handles URI links. Pass null to ignore URI links.
Called when link activation fails.
The maximum zoom multiplier for gesture-driven and programmatic zoom while this view is bound to state. It must be finite and at least 1f.
Whether multi-touch zoom gestures are enabled. Programmatic zoom through state remains available when disabled. Pan deltas are ignored during a multi-touch zoom to avoid competing with scroll.
Configures normal and selected search-result highlights.