EpubController class
Methods
addHighlight ({required String cfi , Color color = Colors.yellow , double opacity = 0.3 })
→ void
Adds a highlight to epub viewer
addUnderline ({required String cfi })
→ void
Adds a underline annotation
checkEpubLoaded ()
→ void
clearSelection ()
→ void
Removes a mark from epub viewer
Clears any active text selection in the epub viewer
completePageText (EpubTextExtractRes result )
→ void
Safely complete the page text completer
display ({required String cfi })
→ void
Move epub view to specific area using Cfi string, XPath/XPointer, or chapter href
Extracts text content from current page
Extract text from a given cfi range,
getChapters ()
→ List <EpubChapter >
Returns list of EpubChapter from epub,
should be called after onChaptersLoaded callback, otherwise returns empty list
getCurrentLocation ()
→ Future <EpubLocation >
Returns current location of epub viewer
getMetadata ()
→ Future <EpubMetadata >
getRectFromCfi (String cfiRange )
→ Future <Rect ? >
Get bounding rectangle for a given CFI range
Returns WebView-relative coordinates in pixels, or null if rect cannot be determined
moveToFirstPage ()
→ void
Moves to the first page of the epub
moveToFistPage ()
→ void
Moves to the first page of the epub
moveToLastPage ()
→ void
Moves to the last page of the epub
next ()
→ void
Moves to next page in epub view
noSuchMethod (Invocation invocation )
→ dynamic
Invoked when a nonexistent method or property is accessed.
inherited
parseChapters ()
→ Future <List <EpubChapter > >
prev ()
→ void
Moves to previous page in epub view
removeHighlight ({required String cfi })
→ void
Adds a mark annotation
Removes a highlight from epub viewer
removeUnderline ({required String cfi })
→ void
Removes a underline from epub viewer
search ({required String query })
→ Future <List <EpubSearchResult > >
Search in epub using query string
Returns a list of EpubSearchResult
setFlow ({required EpubFlow flow })
→ Future <void >
Set EpubFlow value
setFontFamily ({required String fontFamily , String ? fontBase64 , String fontMimeType = 'font/truetype' })
→ Future <void >
Set font family in epub viewer.
fontBase64 is the base64-encoded font file (ttf/otf).
fontMimeType defaults to 'font/truetype' for ttf, use 'font/opentype' for otf.
setFontSize ({required double fontSize })
→ Future <void >
Adjust font size in epub viewer
setManager ({required EpubManager manager })
→ Future <void >
Set EpubManager value
setSpread ({required EpubSpread spread })
→ Future <void >
Set EpubSpread value
setWebViewController (InAppWebViewController controller )
→ void
toProgressPercentage (double progressPercent )
→ void
Given a percentage moves to the corresponding page
Progress percentage should be between 0.0 and 1.0
toString ()
→ String
A string representation of this object.
inherited
updateTheme ({required EpubTheme theme })
→ Future <void >