Skip to main content


Showing posts from January, 2011

Hyperlinking endnotes in ePUBs the easy way: Using Regular Expressions

Following an earlier post on Kindle and ePUB footnotes/endnotes, I wanted to quickly sketch down a way of automating the coding using regular expressions in Open Office . One problem with Regular Expressions and GREP is that while it is easy to identify the end of a paragraph it is not possible to identify sentences in the same way. And although it would seem fairly logical that a sentence begins with a capital, or that there is a full-stop followed by a space followed by a cap, still all the pieces necessary to define the beginning of a sentence in a precise way without hiccup based on the end have eluded me so far. So here's my solution thus far, which may need tweaking depending on the type of project you're working on. And if you find and replace all at once then proof the results afterwards. Anyway, what I would recommend based on the type of work I do, is to replace all note referents with [1], [2], [3] and so on in the text while you edit. Then do the following. Fin

Open Office, Regular Expressions and eBooks

This post (and others that will follow) is for people who have decided that rather than let Pages do the ePUB conversion, or InDesign, or any other program, they want to convert their original Word doc or similar into XML themselves, so that it can then be used for import into InDesign as XML and can also be used as the basis for the XHTML for ePUB and Kindle versions. More importantly it is for people who want to save time. First question: why work on the Word doc in this way instead of the text file in a great program like TextWrangler or BBEdit? Answer: most programs designed for editing text and code do not read Word files or RTF files, so all of the author's formatting (like italics and bold) is lost on conversion into plain text, as are automated footnotes, etc. While you'll end up editing XML files in a text editor eventually, first we need to convert all the word processor specific stuff into something a text editor will retain and pass on to InDesign or Sigil, for

Why Pages won't be entering my publishing workflow

Pages, Apple's word-processing and DTP software, now available from their online App Store for £11.99 is an ideal way to move from Word doc to valid ePUB. Liza Daly has described some of the latest improvements to it in 'EPUB export improvements in Apple Pages 4.0.5' It seems perfect and a dream price for professional publishers and self-publishers alike, and as one of the comments posted in response to Daly's article asserts: with Pages and Sigil you can now construct the perfect ePUB. So why shouldn't publishers leap in head first and start having their teams work with Pages when it is so cheap? Ant: The answer is that most publishers don't simply want an ePUB. Tony: Not a problem, I can use KindleGen to convert to Kindle format from ePUB. Ant: Yes but you'll have to tinker with the CSS and XHTML to make it look perfect in Kindle (see earlier posts). Tony: Fine I can do that. Ant: What about the print version? Tony: I can import Word docs into InD