[rfc-i] ebooks (or pagination considered harmful)

Julian Reschke julian.reschke at gmx.de
Sat Nov 20 08:43:28 PST 2010


Hi,

recently, when discussing the current (paginated) RFC format, ebooks 
were brought up as example devices where pagination not only makes 
sense, but is even required.

That's only true on the surface.

(What follows below applies to the ePub format, but I'd be surprised if 
the Kindle format is significantly different)

Indeed, pre-paginating content is the worst thing you can do *unless* 
the following aspects are known and fixed in advance:

- display format and orientation
- the user's font size preference

To do things properly, the *recipient* needs to do the pagination, 
potentially with the help of formatting hints in the file format.

In the case of the ePub format (as used in iOs and on Sony readers, for 
example), this is done using (X)HTML, plus some metadata files, plus 
CSS, all packaged in a ZIP file (the CSS allows hints for page-breaking).

As a proof-of-concept, I finally brought my scripts for ePub file 
generation into a releasable state; they start from an XML source file 
in the RFC2629 (xml2rfc) format, and need a Unix shell, "zip", plus 
either "saxon" or "xsltproc" as XSLT processors.

Download: <http://greenbytes.de/tech/webdav/rfc2629xslt.zip>

Example: <http://greenbytes.de/tech/webdav/rfc5987.epub>

Note: this is work-in-progress. Among the known issues are:

- no attempt is made to divide chapters across multiple X(HTML) files, 
which makes most reading devices very unhappy for big files

- inlined raster graphics are not supported

Feedback appreciated,

Best regards, Julian







More information about the rfc-interest mailing list