NativePdfView class

Inheritance

Constructors

NativePdfView({Key? key, String? filePath, String? url, Widget? placeholder, Widget errorBuilder(String error)?, String? searchQuery, int currentMatchIndex = 0, dynamic onSearchResultsChanged(int totalMatches, String? error)?, String? annotationMode, int? annotationColor, double? annotationStrokeWidth, VoidCallback? onAnnotationClear, bool enableTextSearch = true, bool enablePanAndZoom = true, bool enableAnnotations = true, String renderQuality = 'high'})
const

Properties

annotationColor int?
Annotation color (ARGB format)
final
annotationMode String?
Annotation mode: "draw", "highlight", "erase", or null
final
annotationStrokeWidth double?
Annotation stroke width
final
currentMatchIndex int
Current index of the search match to highlight
final
enableAnnotations bool
Enable or disable annotations
final
enablePanAndZoom bool
Enable or disable pan and pinch zoom
final
enableTextSearch bool
Enable or disable text search
final
errorBuilder Widget Function(String error)?
Optional error widget to show when PDF loading fails
final
filePath String?
Path to the PDF file (local asset or file path)
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
onAnnotationClear VoidCallback?
Callback invoked when annotations are cleared
final
onSearchResultsChanged → dynamic Function(int totalMatches, String? error)?
Callback for search results changes
final
placeholder Widget?
Optional placeholder widget to show while loading
final
renderQuality String
PDF rendering quality (low, medium, high, ultra)
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
searchQuery String?
Search query to highlight in the PDF
final
url String?
URL of the PDF to load from the internet
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<NativePdfView>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited