Threepress Consulting blog

Threepress creates software for publishers, educators and authors.

Category: tools

Test-driving Apple Pages with ePub export

Finally there’s a commercial word processor that can export ePub.
Today Apple released an update to iWork 9.0.4 that provides ePub as one of the output formats in the Export menu, alongside PDF and Word. Apple has also provided a support page describing the differences between ePub and PDF, and a very helpful [...]

docbook2epub updated to version 1.0.2

Our Python script to convert from DocBook to ePub using the DocBook XSL has been updated to version 1.0.2.
I’ve added some command-line options to override the location of the DocBook XSL (previously it was stuck in a settings file) and to also point to an optional CSS file.

$ db2epub.py
Usage: db2epub.py docbook1.xml [docbook2.xml]… –xsl [DocBook XSL [...]

Tutorial on building ePubs now freely available

My tutorial Build a digital book with EPUB, posted on IBM DeveloperWorks, has been out for some time (November 2008!) but it has recently been updated with some minor corrections. It also no longer requires registration thanks to a policy change at DeveloperWorks.

What’s in an identifier?

ePub books are supposed to have a unique identifier: the Dublin Core identifier found in the OPF file. Unfortunately, the ePub spec doesn’t have any mechanism to enforce the uniqueness of the ID, so we live in a world where in fact many many epubs don’t have truly unique identifiers (or indeed, any identifiers [...]

How to get your bug fixed

Some of the most useful tools in ebook development are open source. Calibre and epubcheck especially come to mind. If you find a bug or want to request a feature, what are the best ways to ensure your needs get attention?
Submit a patch
Of course the holy grail for the lazy open source developer is [...]

Command-line epubcheck results without epubcheck.jar

Most of the time, command-line users will be able to run the epubcheck Java binary without issues. But sometimes mysterious problems occur — this happened to me on OS X before upgrading to Snow Leopard. So while it’s a bit awkward, you can use the remote epubcheck API combined with some XSLT to [...]

3 tiny bash scripts for ePub creation

I wrote these to automate a really common task: zip up an ePub (properly) and validate it. It expects a local install of epubcheck.
Install these functions in your .bash_profile. This should work on any Unix-like system including OS X.
Zip up an ePub file

function epub()
{
rm -f $@; zip -q0X $@ mimetype; zip -qXr9D $@ *
}

Call this [...]

Web-based ePub validator adds Preflight and API

Our web tool for using the open-source epubcheck validator got a quick refresh:
Now includes epubpreflight results
EpubCheck’s lesser-known companion checks for additional issues like content documents that exceed 300K, which can’t be loaded on the Sony Reader. The complete (short!) list:

Content files that are empty or are >300k
Image files that are empty or are >10MB [...]

Five ebook conversion tips

In the last few years many technology blogs have been participating in “National Blog Posting Month,” a play off the more famous National Novel Writing Month.
Threepress is participating: we’ll be posting ebook technology tips, code samples and updates on our projects every day for the whole month of November. Hopefully we’ll include [...]

Open Feedback Publishing System launched

O’Reilly is announcing today that the in-progress book, Programming Scala, has been released using the Open Feedback Publishing System, a platform I built for them that allows public commenting on digital manuscripts.
Users can comment using the web site, read the entire in-progress text of the book (updated as the authors revise it), or [...]