Skip to content

jumper047/fb2-reader

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FB2-reader

https://melpa.org/packages/fb2-reader-badge.svg

Plugin for Emacs to read FictionBook2 ebooks.

Features:

  • read .fb2 and .fb2.zip files
  • reach book formatting
  • showing current title in header line
  • internal links (select from keyboard, jump back and forth)
  • navigation (next/previous chapters, imenu support)
  • restoring last read position
  • displaying raw xml
  • book info screen
  • table of content in separate buffer

Coming soon:

Screenshots

Main window

./images/main_window.png

Header line

./images/headerline.gif

Metadata screen

./images/metadata.png

Book loading screen

./images/splash_screen.png

Outline

./images/outline.png

TL;DR

Add to your config and open any .fb2 or .fb2.zip document.

(use-package fb2-reader
  :mode ("\\.fb2\\(\\.zip\\)?\\'" . fb2-reader-mode)
  :commands (fb2-reader-continue)
  :custom
  ;; This mode renders book with fixed width, adjust to your preferences.
  (fb2-reader-page-width 120)
  (fb2-reader-image-max-width 400)
  (fb2-reader-image-max-height 400))

Installation

Install fb2-reader from MELPA and add that string to your config:

(require 'fb2-reader)

Also you can set it up with use-package:

(use-package fb2-reader
  :commands (fb2-reader-continue))

Customization

Every book rendered as buffer with certain width, so you may want to tune variables related to your monitor’s size or reading preferences:

  • fb2-reader-page-width - width of rendered book
  • fb2-reader-image-max-width and fb2-reader-image-max-height - max. width and height of an images in book.

You can view all available options with M-x customize-group fb2-reader.

Usage

Just open an .fb2 or .fb2.zip file. First opening will take a time - book will be rendered and saved to cache, so all next ones will be quick. You can continue reading by executing M-x fb2-reader-continue. Key bindings listed below:

Fb2-reader:

KeyAction
[, ]Jump to previous or next chapter
p, nJump to previous or next displayed link
l, BJump to last used link’s location
B, NJump to last used link’s target
gReload current book
vView current book as xml
xReopen fb2.zip document as archive
iView FB2 metadata
jJump to chapter via imenu
o, tShow TOC outline
cToggle no-cursor mode

Metadata:

KeyAction
p, nJump to previous or next field
P, NJumps to previous or next category
cToggle no-cursor mode
qQuit window

Outline:

KeyAction
p, nJump to previous or next heading
RETFollow link
C-o, SPACEDisplay link (withoiut switching to fb2 buffer)
M-RETFollow link and quit TOC window
o, tSwitch to fb2 window
qQuit TOC window
QKill TOC window

Aknowledgements

Heavily inspired by @spline1986’s fb2-mode. Also kudos for @vlichevsky - his testing is extremely helpful!

About

Emacs plugin to read .fb2 and .fb2.zip ebooks.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published