Difference between revisions of "ePub"

From Wiki
Jump to navigation Jump to search
m (comment xhtml file)
(add some external links)
Line 4: Line 4:
  
 
The ePub facilities of ConTeXt are based on its [[Export]] of XML/XHTML. Make sure you get useful export output from your project before you try ePub.
 
The ePub facilities of ConTeXt are based on its [[Export]] of XML/XHTML. Make sure you get useful export output from your project before you try ePub.
 +
 +
= Documentation about ePub =
 +
 +
* [https://en.wikipedia.org/wiki/EPUB Wikipedia entry] with some examples
 +
* [http://idpf.org/epub/20/spec/OPF_2.0.1_draft.htm Open Packaging Format] (OPF) 2.0.1 specs; contains also information about NCX
 +
* [https://www.iso.org/standard/53255.html ePub3 ISO/IEC TS 30135-1:2014] (Buy specs for 118 CHF?)
 +
* [https://github.com/w3c/epubcheck ePub Check] validator (most validation tools are based on this)
  
 
= Minimal ePub =
 
= Minimal ePub =

Revision as of 09:26, 6 March 2020


TODO: This page is work in progress and an update to the current pages Epub and Epub_Sample. (See: To-Do List)


< XML | Export | Old ePub docs | Old ePub Sample >

The ePub facilities of ConTeXt are based on its Export of XML/XHTML. Make sure you get useful export output from your project before you try ePub.

Documentation about ePub

Minimal ePub

If you already ran ConTeXt on your project and got the file structure as described in Export, you can run mtxrun --script epub --make minimal to get a structure like:

minimal.epub
minimal-epub
├── META-INF
│   └── container.xml
├── OEBPS
│   ├── cover.xhtml
│   ├── images
│   ├── minimal-div.xhtml
│   ├── minimal.opf
│   ├── nav.xhtml
│   ├── styles
│   │   ├── minimal-defaults.css
│   │   ├── minimal-images.css
│   │   └── minimal-styles.css
│   └── toc.ncx
└── mimetype
  • .epub: The epub file is just a zipped version of the directory structure.
  • mimetype: contains only "application/epub+zip"
  • container.xml points to the root file "minimal.opf"
  • cover.xhtml is the cover image shown by ePub readers
  • -div.xhtml: your content
  • .opf: list of all resources, this keeps the "book" together. See also OPF specs.
  • .ncx: table of contents

TODO

Write about

  • Cover
  • ToC
  • Readers
  • Styling
  • Images
  • Better workflow