PdfViewer constructor

const PdfViewer(
  1. PdfDocumentRef documentRef, {
  2. Key? key,
  3. PdfViewerController? controller,
  4. PdfViewerParams params = const PdfViewerParams(),
  5. int initialPageNumber = 1,
})

Create PdfViewer from a PdfDocumentRef.

documentRef is the PdfDocumentRef. controller is the controller to control the viewer. params is the parameters to customize the viewer. initialPageNumber is the page number to show initially.

Implementation

const PdfViewer(
  this.documentRef, {
  super.key,
  this.controller,
  this.params = const PdfViewerParams(),
  this.initialPageNumber = 1,
});