H2NH eBook Formatting Workflow
Note!
This is the bare-bones, no explanation workflow that H2NH uses to produce an eBook in various formats. If you want a detailed overview and step-by-step walk-through, please consult Paul Salvette's excellent eBook Formatting Guide: Details
TXT to:Note!
This is the bare-bones, no explanation workflow that H2NH uses to produce an eBook in various formats. If you want a detailed overview and step-by-step walk-through, please consult Paul Salvette's excellent eBook Formatting Guide: Details
*DOC - PDF
*HTML - EPUB, MOBI
Operating System
Ubuntu 11.04
Note: All programs below are available on Windows XP & Mac OS X
Programs
FocusWriter
-features: convenient timer and word count
-option for RTF format
-multi-platform
-full-screen text editor
LibreOffice 4.3 for DOC and PDF
-better styles than Microsoft Office
-multi-platform, free software
-DOC works at Smashwords
jEdit for HTML
-robust, convenient
-multi-platform
-make a macro!
GIMP for cover art
-works fine for journeyman editing
-more cost-effective than Photoshop
-multi-platform
-free software
calibre for conversion to EPUB and MOBI
-easy conversion, table of contents creation
-also useful for managing eBook library
FocusWriter
writing, editing
by Paul Salvette
which explains pretty much everything better than I can.
type, use -- for — (em dash)
LibreOffice
pre-formatting
pre-formatting
double quotes : " with "
single quotes : ' with '
em dash : -- with —
ellipses : ... with …
Format for Smashwords, save a copy as DOC
Format for PDF, save a copy as PDF
for HTML, find and replace:
Ctrl-i to
<i>^&</i>
jEdit
search and replace
search and replace (use Macro):
” with
”
“ with
“
‘ with
‘
’ with
’
… with
…
— with
—
è with
è
é with
é
paragraphs:
^(.+)$
with <p>$1</p>
search for <p></i> and fix
Bold with
<strong>Bold</strong>
Strikethrough with
<del>Strikethrough</del>
jEdit
styles
Apply this header, wrap with body tags
<?xml version="1.0" encoding="utf-8"?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><head><style type="text/css">html, body, div, h1, h2, h3, h4, h5, h6, ul, ol, dl, li, dt, dd, p, pre, table, th, td, tr { margin: 0; padding: 0em; }p{text-indent: 1.5em;margin-bottom: 0.2em;}p.noindent{text-indent: 0em;margin-bottom: 0.2em;}p.preview{margin-top: 5em;margin-bottom: 2em;}p.title{page-break-before: always;font-size: 3em;font-weight: bold;margin-top: 5em;}p.subtitle{text-indent: 3em;font-size: 2em;font-weight: bold;}p.author{text-indent: 3em;font-size: 2em;}p.matter{text-indent: 3em;font-size: 1.5em;}p.chapter{page-break-before: always;text-indent: 1.5em;font-weight: bold;font-size: 2em;margin-top:5em;margin-bottom:2em;}p.story{text-indent: 1.5em;font-size: 1em;margin-top: 5em;margin-bottom: 0.2em;}p.centered{text-indent: 0em;text-align: center;}span.centered{text-indent: 0em;text-align: center;}</style></head><body></body>
Book Chapters/Collection Stories =
<p class="chapter">Chapter Title</p>
Individual Short Story 'chapter' (for clean ToC) =
<p class="chapter" style="display:none">Short Story Title</p>
<p class="story">First paragraph of text</p>
Apply other styles as appropriate.
*** with <p class="centered"><span class="centered">***</span></p>
To insert centered pictures between lines, put an image file [example.jpg] into the same directory as the html file, and then use:
<p class="centered"><span class="centered"><img src="example.jpg" alt="example" /></span></p>
Search for & in browser window, then manually replace & with
&
in jEdit
GIMP
cover art
Post: Cover Art (by me!)
Calibre
conversion
Add HTML to Calibre, edit metadata, add cover
Convert to EPUB
Table of Contents
Level 1 TOC (XPath Expression) = //h:p[re:test(@class, "chapter", "i")]
EPUB Output
check 'Preserve cover aspect ratio'
Convert to MOBI
Upload formats as appropriate.
Samples
Collection |
Short Story |
Comments: DavidalBarron [at] gmail [dot] com
eBook Formatting Tutorial
If you've become lost in this rough-and-ready workflow, please see the excellent
by Paul Salvette
which explains pretty much everything better than I can.
Notes to me: --
Resource: http://epubzengarden.com
To be explored: http://code.google.com/p/sigil/