Electronic publication epub: the e-book

Bearing_Witness_A5I have now converted my book to electronic format.

Some say pdf is the ‘de facto’ format for electronic publication. It can be used for computers on all platforms.

However for other devices like mobile phones or tablets, it seems the EPUB format is better or more useful. I read a few manuals and ‘how to’s but somehow they all turned up to be over complicated, so here is a more simple how to convert to epub.

I used calibre, which is also available for all computer platforms apparently. For information, I use ubuntu/linux, and the program I had writen my book with was OpenOffice, now LibreOffice.

The Calibre manual I read says it can import from all sorts of formats, from docx to txt going through odt, rtf, even pdf. However: without high expertise in ‘html tags’, ‘regular expressions’ and the like, I found it est to just use good ol’ text: In LibreOffice, I exported the book to plain text , to a .txt file and then converted from there. Yes all the pictures were lost but so were, in my case, lots of formatting that were in the text showing as unsorted html things in the middle of my sentences.
So: first step, export, or save the book file, as text, format: txt.

Then in calibre, ‘add books’. Although it is best to add just one by one of course. Especially if the computer at hand doesn’t have massive amounts of memory. The ‘add books’ menu will allow to browse through the files in the computer so the text file just created can be opened from there.

Next step is to edit the metadata. There is a bit of typing to do and after many trial-error stages, I typed all necessary data like the author etc in a separate text file so in subsequent tries I just had to copy and paste to save a bit of time and frustration. (yes the process can be frustrating if you have just a bit of fancy formatting or you just fancy having a functioning table of contents; more of this later).

There is a button in these two steps, from what I remember, called ‘next’. It does not refer to ‘next step’, but to ‘next book’. If you click on next and continue editing, you will be changing the metadata of the existing book, which in my version of Calibre was the manual to calibre itself. So don’t click next to go to the next step of converting your own book. Click ‘ok’.

Importing the book from the text file took a few seconds. My book is about 60K words. I learned that if this step was longer than a minute, it was because I had too many programs opened or my computer was dying. So my advice would be to restart the computer and start with just Calibre open.

Next step: ‘Convert books’. I just converted from .txt to .epub, and then apparently it is easy to convert from .epub to the other formats, but for now I’ll use just .epub until otherwise necessary.

Calibre has this facility to email the converted file to yourself, though it has to be a gmail account. It also has the facility to save all files to a folder in your computer apart from the calibre library itself. For some reason this is the step that always took the longest, so using the gmail facility may be faster. I used this method to transfer my epub to a tablet, to actually see how it looked like.

And here is where the trial and error started because the table of contents didn’t transfer properly at all. For a start, the table I had in my .odt-to-print file came up as simple text where the chapters and the pages had lost touch with each other completely. And the only contents to appear in the epub’s table were the Prologue and the Epilogue, despite these two having exactly the same formatting as all the rest of the headers.

Now, the manual I was using suggested a few ways of formatting the chapters so that Calibre would identify them as such to create a Table of Contents (TOC) that would be useful for readers.

I couldn’t get any of those formats to function. In the end the only thing that worked was to add the word “Chapter” to each heading that I wanted to appear in the TOC. So, the ‘Preparations’ header, I named “Chapter 1: Preparations”, then “Chapter 2: First week” and so on.

I had to do all these changes in the text file using the text editor (Gedit in Ubuntu). There is no way to edit the text in Calibre; it is not a text editing program. So for each change, the process was to go back to the text file, do the edits, then go to calibre and start the whole process again, to add the book, then change the metadata to enter the title, author, publisher, isbn etc., then convert to epub, then two ways to ‘proofread’: to view in calibre – for that you right-click on the book and choose ‘view a specific format’ and choose epub – and to send it to a tablet or whatever external device people usually read ebooks on, and open it there.

Since this site does not accept uploads of files like .pdf for security reasons (guess it won’t accept epub either), and I fail to understand commercial or even ‘netowrking book fan’ sites, I have decided to make my books available through here; to get the physical book on the post or the electronic one by email, people can post a comment indicating that they wish the comment to not be published and an email address to continue the conversation, so the books can be sent in exchange of a voluntary donation.

There are some published chapters to get an idea of the book.