A 2011 Sydney Linux Users Group Presentation by Marghanita da Cruz
Part 1 Writing and Formatting the Book | Part 2 Interoperability | Part 3 1890s Annandale: A short Walk - The Book | 1890s eBook | Paperback Edition | iBook
The book comprises text, photographs, a "line drawing" created from a photograph, end notes and web references.
I composed and formatted the book in Open Office. However, with hindsight this was not the best approach. It would have been better to format the document in XHTML - the basis of the EPUB Format required by Lulu.
Tom Worthington and the four websites, listed below, were invaluable in doing this. The firefox Google Chrome EPUBReader plugin, allows you to display and read e-pub books in the browser.
The advice was to break the book up into separate files for each chapter. I chose to go with 7 files of XHTML. The W3C Markup Validation Service's Tidy was useful in converting my HTML to valid XHTML.
Each image, in the book, will be a file. A css style sheet and three other files are also required, in a specific directory format, in the E-PUB Package. Harrison Ainsworth's Epub Format Construction Guide explained this structure well.
"The following issues were found with your EPUB, which can effect its eligibility for certain channels:
* Did not pass epubcheck-1.1 validation. (the iBookstore and Barnes & Noble)
* Contains invalid creator XML. (Barnes & Noble)
* Contains invalid publication date XML. (Barnes & Noble)"
ERROR mimetype -1 -1 Mimetype file should contain only the string "application/epub+zip".
The mimetype file must be added as uncompressed file zip -0 file.epub mimetype the (zero not oh) "store only" option does this. However, the new epub file still returned the error "extra field length for first filename must be 0, but was 21". This further suggestion from SLUG, "zip -0 -X file.epub mimetype" did the trick - but the mimetype file must be put into the container before any other files.
Alternatively, you can download this container stub (containing the mimetype file and META-INF folder and container.xml file), change the name to one with an .epub extension, and add your e-book content in a OEBPS Folder: mimetype.zip
zipinfo -mt file.epub is a useful command for displaying information about the zip file. Including compression and file length.
Ebook available through Lulu
Perhaps the biggest issue is the hyperlinks. Where it is sufficient to provide hyperlinks, to references and relevant material on the web, it isn't really practical for a reader of the hard copy to follow up as easily. They are also more likely to flick through the book and so, would benefit from the inclusion, or at least a description, of what is available at the link - for possible follow up.
There are limitations on the book formats (bindings, page size, number of pages) which are available, for distribution, through Lulu Channels. For Global Reach the parameters are :U.S.Trade6x9", BlackandWhite PerfectBound 48-740pages. This was more pages than my e-book, but I decided to increase the font size (14point is more readable) and include additional photographs. As these were not my photographs permission needed to be obtained.
Lulu produces paperbacks from PDF files. I used Open Office to create the PDF. In addition, if you want to include an image on the front cover of your book or control the look, you will need to do this in a JPG file. You also have the option to provide another JPG, to be included on the backpage. Lulu also lets you enter the text for the cover pages directly. I did not like where Lulu wanted to put this text, so included it in my front cover image. The back cover adjusts the text around the image you provide. There is a "new" feature in Lulu which lets you design your whole front and back page.
An EPUB provides the ability to hyperlink within the document and the Internet, eg from the Table of Contents, to referenced points in the book or from references to sources on the web. These hyperlinks disappear in the paperback. It is useful to think about this when creating your html.
Open Office has a Master Document feature. Create one of these and import each of the HTML Files.In Open Office, you can format each page - to adjust the size (Lulu Paperback 6"x9"), specify page size, margins, footers and headers for cover, front matter, left and right pages etc. Tip - this is done by right clicking on the
In theory, it should just be a matter of linking to the HTML files published as the epub. In reality, first you have to strip the first couple of lines the EPUB format requires, then deal with the formatting challenges (in Open Office 2.4.1).
When you are happy with the display of your document export it as PDF.
Note you can save the Master File (ODM Package) - but you need to reapply the page style to the cover page, others flow on, each time you open the document. Possibly a bug in Open Office 2.4.1
I converted the images to grey scale for a Black and White only Printed book. But this may not be necessary. Lulu also provides the option (at significantly higher cost) for colour.
Part 2 Lightning Talk at SLUG 26 August 2011 - Interoperability - Formatting the PDF from the HTML source using Open Office Master Document.
Lulu also lets you publish your book as PDF, so to do this you will need to decide whether your PDF is for printing or electronic use and change the Internet and Visited Link Character attributes back to something suitable. Also replace the printed Table of Contents with the Hyperlinked version.
Youtube: Lightning Talk at Sydney Linux Users Group (29 July 2011)
www.ramin.com.au/linux/formatting-e-books-and-paperbacks.shtml © Ramin Communications 2007-11. Last modified 15 August 2012.