Starlight Epub Viewer
starlight_epub_viewer is an epub ebook reader that encapsulates the folioreader framework. It supports iOS and android.
Features
Name | Android | iOS |
---|---|---|
Reading Time Left / Pages left | |
|
Last Read Locator | |
|
Highlight And Notes | |
|
Load ePub from Asset | |
|
Share | |
|
Distraction Free Reading | |
|
ScreenShots (Android)
ScreenShots (Ios)
Installation
Add starlight_epub_viewer as dependency to your pubspec file.
starlight_epub_viewer:
git:
url: https://github.com/YeMyoAung/starlight_epub_viewer.git
Android Setup
No additional integration steps are required for Android.
Ios Setup
This plugin requires Swift
to work on iOS.
Add the following lines in the Podfile
file of your iOS project
platform :ios, '9.0'
...
target 'Runner' do
use_frameworks!
use_modular_headers!
pod 'FolioReaderKit', :git => 'https://github.com/YeMyoAung/starlight_folioreader.git'
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
end
Usage
First of all you need to import our package.
import 'package:starlight_epub_viewer/starlight_epub_viewer.dart';
And then you can use easily.
/// Config
StarlightEpubViewer.setConfig(
///for viewer color
themeColor: Colors.blue,
///night mode for viewer
nightMode: false,
///scroll direction for viewer
scrollDirection: StarlightEpubViewerScrollDirection.ALLDIRECTIONS,
///if you want to share your epub file
allowSharing: true,
///enable the inbuilt Text-to-Speech
enableTts: true,
///if you want to show remaining
setShowRemainingIndicator: true,
);
/// Open From File
StarlightEpubViewer.open(
"file path",
);
/// Open From Assets Folder
StarlightEpubViewer.openAsset(
"assets file path",
);