kepub

package
v2.3.2+incompatible Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 25, 2019 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const FullScreenFixesCSS = `` /* 136-byte string literal not displayed */
View Source
const HyphenateCSS = `` /* 345-byte string literal not displayed */
View Source
const NoHyphenateCSS = `* {
	-moz-hyphens: none !important;
	-webkit-hyphens: none !important;
	hyphens: none !important;
}`

Variables

This section is empty.

Functions

func PackEPUB

func PackEPUB(src, dest string, overwritedest bool) error

PackEPUB packs an epub

func UnpackEPUB

func UnpackEPUB(src, dest string, overwritedest bool) error

UnpackEPUB unpacks an epub

Types

type Converter

type Converter struct {
	PostDoc         func(doc *goquery.Document) error // post-processing the parsed document
	PostHTML        func(h string) (string, error)    // post-processing the resulting html string (after PostDoc)
	ExtraCSS        string                            // extra css to add
	NoHyphenate     bool                              // force disable hyphenation
	Hyphenate       bool                              // force enable hyphenation
	InlineStyles    bool                              // inline all stylesheets
	FullScreenFixes bool                              // add css to fix FullScreenReading (probably not needed since 4.11.11911)
	FindReplace     map[string]string                 // find and replace on the html of all content files
	Verbose         bool                              // verbose output to stdout during conversion
}

func (*Converter) CleanFiles

func (c *Converter) CleanFiles(epubDir string) error

func (*Converter) Convert

func (c *Converter) Convert(src, dest string) error

func (*Converter) ProcessHTML

func (c *Converter) ProcessHTML(html, filename string) (string, error)

ProcessHTML processes a html file. filename is the full path to the file and is required if inlining styles.

func (*Converter) ProcessOPF

func (c *Converter) ProcessOPF(opf string) (string, error)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL