FolioReaderKit - 一个Swift开发用于iOS应用的ePub读取和解析框架

jopen 9年前

qq截图20160121165327.png 
FolioReaderKit - 一个Swift开发用于iOS应用的ePub读取和解析框架。

Installation

FolioReaderKit is available through CocoaPods. To install it, simply add the following lines to your Podfile:

use_frameworks!  pod 'FolioReaderKit'

Requirements

  • iOS 8.0+
  • Xcode 7.1+

Basic Usage

To get started, this is a simple usage sample.

import FolioReaderKit    func open(sender: AnyObject) {      let config = FolioReaderConfig()      let bookPath = NSBundle.mainBundle().pathForResource("book", ofType: "epub")      FolioReader.presentReader(parentViewController: self, withEpubPath: bookPath!, andConfig: config)  }

In your AppDelegate call applicationWillResignActive and applicationWillTerminate. This will save the reader state even if you kill the app.

import FolioReaderKit    func applicationWillResignActive(application: UIApplication) {      FolioReader.applicationWillResignActive()  }    func applicationWillTerminate(application: UIApplication) {      FolioReader.applicationWillTerminate()  }

Features

  • Custom Fonts
  • Custom Text Size
  • Text Highlighting
  • List / Edit / Delete Highlights
  • Themes / Day mode / Night mode
  • Handle Internal and External Links
  • Portrait / Landscape
  • Reading Time Left / Pages left
  • In-App Dictionary
  • Media Overlays (Sync text rendering with audio playback)
  • Book Search
  • Add Notes to a Highlight
  • Better Documentation

Demo

Custom Fonts :smirk:

Custom fonts

Day and Night Mode :sunglasses:

Day night mode

Text Highlighting :heart_eyes:

Highlight

Reading Time Left :open_mouth:

Time left

Documentation

For now the documentation is the sample project, I will write a better documentation in the next weeks.

You have a problem that cannot be solved by having a look at the example project? No problem, let's talk:

Author

Heberti Almeida

Donations

This project needs you! If you would like to support this project's further development, the creator of this project or the continuous maintenance of this project, feel free to donate. Your donation is highly appreciated. Thank you!

PayPal

  • Donate 5 $: Thank's for creating this project, here's a tea (or some juice) for you!
  • Donate 10 $: Wow, I am stunned. Let me take you to the movies!
  • Donate 15 $: I really appreciate your work, let's grab some lunch!
  • Donate 25 $: That's some awesome stuff you did right there, dinner is on me!
  • Donate 50 $: I really really want to support this project, great job!
  • Donate 100 $: You are the man! This project saved me hours (if not days) of struggle and hard work, simply awesome!
  • Of course, you can also choose what you want to donate, all donations are awesome!

License

FolioReaderKit is available under the BSD license. See the LICENSE file.

项目地址: https://github.com/FolioReader/FolioReaderKit