Sunday, June 6, 2010

Announcing “ePub: Straight to the Point” plus TOC!

I am proud to announce the imminent publication of my new book, ePub: Straight to the Point, which explains how to use a text editor, Word, and/or InDesign to convert a manuscript into an ePub document that looks gorgeous and is pleasing to read on the iPad and other ereaders.

For those curious about what the book will cover, I offer you the (current and tentative) Table of Contents, which is pretty close to final. However, since I tend to tweak things right up til the end, I can't guarantee that I won't add a few more things, especially to the "Advanced Formatting" chapter. It's also possible that page restraints will relegate the "Adapting plain text for ePub" section to my blog, though I had a great time putting GREP through its paces.

The print edition will be published and distributed by Peachpit Press, and is already available for pre-order on Amazon and Barnes & Noble.

There will also be an ePub edition, which will take full advantage of the very techniques discussed in the book itself, which will be available from all the aforementioned websites, as well as my own.

You can follow me on Twitter for all the latest news about my book, and about ePub production (#eprdctn) in general!

Table of Contents for ePub: Straight to the Point

Introduction

Print vs. ebook vs. website

Static vs. Dynamic

Appearance

How it’s read

The order of things

Formats, durability, and batteries

Searchability

Highlighting and sharing passages

Copy protection

Buying new books

What is an ePub document?

Navigating a sea of ereaders

Anatomy of an iPad page

Getting your eBook content

Using public domain content

Dealing with plain text

What about rights?

Using Word to write ePub

Styling your Word document

Setting up styles in Word

Applying styles

Saving Word files as HTML

Preparing HTML files for ePub

Using a text editor

Declaring the file to be XHTML, not HTML

Moving style data to its own file

Declaring the language used

Adding quotation marks around attributes

Using InDesign to create ePub

Creating an InDesign document

Creating a template for your InDesign files

Creating your styles

Loading existing styles

Cleaning up and saving the template

Organizing the InDesign files with an InDesign Book

Adapting plain text for ePub

Removing extra returns

Removing extra spaces

Converting plain text formatting to styles

Converting double dashes to em dashes

Applying styles to the book

Applying the main Body style

Applying headers, quotes, and other special styles

Replacing local formatting with styles

Drop Caps and Nested Styles

Adding images

Placing an image

Creating text wrap within the flow

Adding links

Creating a style for links

Hyperlinks

Cross-references

Creating a table of contents menu

Preparing your book in order to create the table of contents menu

Creating a Table of Contents Style

Adding Metadata to your ebook

Exporting ePub from InDesign

Exporting ePub from InDesign CS4

Exporting ePub from InDesign CS5

Inside an ePub file

Unzipping an ePub

The files that make up an ePub

The mimetype file

The META-INF folder

The OEPBS folder

XHTML and CSS files

The toc.ncx file for the table of contents

Writing the content.opf file

Creating the cover

Zipping and testing

Organizing files before rezipping

Rezipping after edits

Getting the new ePub file to the iPad

Further editing, rezipping, and testing

Validating your ePub file

Advanced ePub Formatting

Cleaning up InDesign ePub files

How InDesign writes XHTML

How InDesign writes CSS

Making sure ereaders use your CSS

Fonts in your ebook

The Palatino Bug

Specifying fonts by name

Specifying fonts by style

Specifying alternate fonts

Ornaments, dingbats, and symbols

Using non-English fonts

Embedding fonts

Drop caps and small caps

Having CSS mark the first letter and line

Tagging the first letter and first line explicitly

Controlling spacing

Controlling indents

Dealing with short lines

Borders and backgrounds

Creating a sidebar

Hyphenation

Adding soft hyphens

Using left-aligned text

Working with images

Size

Wrapping text around images

Wrapping text around sidebars

Creating links

Creating tables

Video in your ebook

Creating your video

Adding code for the video

18 comments:

  1. Liz, I've already ordered this book, but wouldn't it make sense to talk about how to construct a source file directly in XHTML? Instead of using Word or InDesign as the primary program and then spending a lot of time fixing the file -- which seems very roundabout -- why not use Dreamweaver?

    I'm still exploring the best options for workflow, but right now it's looking like this: If starting from InDesign, export to RTF. If starting with Word, stick to Word. Open either file in the Mac's TextEdit and export to XHTML 1.1 with no CSS. Yes, strip out all styles.

    Then open that in Dreamweaver and apply styles based on minimal, custom CSS. Finally, import the XHTML file into ecub (which Apple itself recommends) or Jutoh (the more full-featured version of ecub) for epub packaging. It can even generate a Kindle file at the same time.

    One thing that keeps me from writing directly in Dreamweaver is lack of smart quotes support. But it might be worth it even so. Anyway, the point is that XHTML 1.1 is the language of epub, and the more directly you can work with that, the less hassle and the more controllable the process.

    ReplyDelete
  2. Hi Aaron. Thanks for your comments, and thanks for ordering my book. I hope you find it useful.

    There are two principal reasons why I chose to focus on InDesign as a principal means of creating an ebook. First and foremost, most books have a print edition as well as an electronic edition. InDesign lets you do both.

    Second, constructing an ePub in XHTML directly, by hand, is a drag. I'm a hand-coder by preference, and I'm telling you, it's just not that fun. I vote for letting InDesign do the busy work—especially, if a print edition already exists or needs to exist.

    Notwithstanding those two points, I'm intrigued about the use of Dreamweaver as an ePub tool and have heard people use it for working on ePubs (over a text editor) simply because it's part of the package. I'll definitely be doing some work in this area in the future.

    ReplyDelete
  3. One more thought. My book *does* contain all the info you need to write your XHTML and CSS, and particularly the toc.ncx and content.opf files by hand, precisely because I like to do that sort of thing.

    ReplyDelete
  4. Hi Liz,

    I work in digital publishing and of course I'm very interested in your book! I don't see any Canadian sites listed and I'd like to buy the epub version of the book. Will your book be available in Canada?

    Thanks,
    Emma
    emma_cunningham@harlequin.ca

    ReplyDelete
  5. Yes, it will be available in Canada. As soon as I know where, I'll post it. And yes, there will be an ePub version... I'll post that too once I have a link. Thanks for your interest!

    ReplyDelete
  6. Thanks, Liz. I don't intend to try to hand code all the epub files, but I figure the primary XHTML file can't be any more complex than coding a Web page -- and I've been using "literary" styles on my Web site for about a decade -- smart quotes, indented paragraphs and all. Once I get the primary file, ecub will generate the others. So, I'm glad you're including that info.

    My take on the InDesign issue is that print publishers are NOT going to be the majority of epub publishers. Instead, you're going to see an influx of self publishers who have never published in print at all. To buy and learn InDesign, with its arcane print technology, high cost, and steep learning curve, will be way beyond what would be sensible for these people to invest.

    At the same time, InDesign CS5 doesn't even seem to do a very good job of generating epub files, at least from my initial tests. Italics, for instance, are lost unless you're embedding fonts, because InDesign creates them with separate fonts instead of stylings. And my test conversions didn't even pass epubcheck.

    By the way, my start in HTML was with your book on HTML 4. We've all evolved a long way since then, but that book is still on my shelf!

    ReplyDelete
  7. Aaron... we've taken an approach like yours; we build the content in WordPress (or any decent Web CMS, really), then build the ePub out of the XHTML. We also transform the XHTML into IDML (XML file format for InDesign since CS4), so we're able to go to InDesign as an output format, rather than as a content-development format -- for text-heavy books, this makes more sense, as far as I can see.

    For an example, see http://tkbr.ccsp.sfu.ca/bookofmpub

    ReplyDelete
  8. Book is available for preorder in Canada from amazon.ca.

    Lindsey

    ReplyDelete
  9. Aaron,

    InDesign CS5 will export italic and bold without embedded fonts but one must apply these effects using a character style. This generates, e.g., class="italic" (in a span element). Whether this is clean code or will be rendered consistently by all reading systems is another question.

    I think you are wrong about how quickly established publishers, who have hitherto been publishing in print, will become a minority of epub publishers. They have enormous backlists that they are now gearing up to convert for digital publication and distribution. But, you are certainly right that self-publishers who are not going to publish in print have no need to buy and learn InDesign. And, in the long run, publishers of all sizes and types will need to adopt a system like that described by John.

    ReplyDelete
  10. Lindsey, there's a difference between producing a majority of books and forming a majority of publishers. There are many, many times more self publishers and micro publishers than mid-size or large commercial publishers -- and the largest commercial publishers aren't likely to be waiting for Liz's book anyway.

    I doubt very much that anywhere near the majority of Liz's audience is going to be InDesign users. Word will probably be the biggest, and InDesign will have to split the rest with OpenOffice, TeX, Apple Pages, Dreamweaver, and many more. The biggest need, though, is for hands-on info, because there's a high level of frustration with the poor formatting that comes with automated conversion.

    Maybe my view is slanted, though, because I'm a small publisher (and DIY Web designer) myself.

    ReplyDelete
  11. Many, many thanks for not writing a book on "how to construct a source file directly in XHTML." Most of us aren't masochists. Your focus on Word and inDesign is where the interests of the great majority of writers and publishers lie. Our desire lies in making the content we create look good. I'm looking forward to getting your book, particularly the ID parts.

    Once this project is out of the way, you might want to take a look at a highly popular writer's tool called Scrivener.

    http://www.literatureandlatte.com/scrivener.html

    Right now, it's Mac-only, but a Windows version is under consideration. It matters, because the 2.0 version, due out in the fall, will include direct export to ePub. If the developer can pull that off, it could mean that there will be one application that could take writers from a rudimentary outline to an almost publishable ebook.

    ReplyDelete
  12. @Inkling Thanks for the tip. I think Scrivener looks really interesting (I keep telling myself I'll write fiction one day), and I didn't know they were going to include Export to EPUB. Awesome.

    There's also Storyist. Do you know it? It looks interesting too.

    And yes, constructing all those files purely in XHTML is too much, even for a hand-coder like me.

    ReplyDelete
  13. I am looking forward to buying your book. I just bought your book on (X)HTML on the Kindle app (I read it on my Kindle, too) and I am really enjoying it.

    One question: Will you be going into detail in this book about what kind of CSS iPad supports? I just tried making a "list-style-image: url('flower.png');" and it didn't work. It would really be a big time saver if you had a list as to what iBooks supports.

    I thought you might want to know before I bought your book as e-book I was deciding between yours and CSS - The Missing Manual. I downloaded samples of both, and it was an easy choice. Yours was clearly well prepared for an e-book, while CSS The Missing Manual was obviously batch converted and looked horrible.

    ReplyDelete
  14. Hello,
    I have been looking for a book on creating epubs so I plan to buy it. I am primarily a hobbyist so all the attention apparently paid in the book to InDesign is also a disappointment to me.

    One application that I think will be my preferred word processor is Atlantis since the html that it exports is "cleaner" than Word, plus the fact I can save in the epub format and then later open it in Sigil if I want to modify it further--or alternatively unzip and open the html files in Dreamweaver.

    ReplyDelete
  15. @purcelljf You'd find Chapters 3 and 4 useful. They deal with the nuts and bolts of EPUB and how to write XHTML and CSS to get the most out of it.

    ReplyDelete
  16. Hi Liz, I am reading the book, it is great. But I miss some info about rezipping the epub the correct way for a non Mac user. Is there any detailed advice about that that you can suggest me? I use Winrar but I am not sure about the right way and order to add the files.

    ReplyDelete
  17. Hi Alex: The way I describe in the book is for all platforms, from the command-line. Are you having problems with it?

    ReplyDelete
  18. Hi

    Fist of all, I'm sorry my English is not to good, bat it is not may native language. I'm Portuguese.
    I bought your book and read it all. It has been most helpful for me to start learning how to publish eBooks.
    I'm converting Adobe Indesign files to digital editions. Everything is working well except for one situation. I've made a TOC that referenced to all chapters in one Indesign file. The problem is that I've made a manual content page in the beginning of the book but it does not work. All links I've created seem to link to the content page(?).
    So I've tried to make this in another way: Fist I've created the cross references links and footnotes and then published the epub file. All was working well. After that I've created the TOC and I was back to square one. I have a working TOC but no other links.
    Do you have any idea what I am doing wrong?
    Is this a CS5 bug?
    I've followed all the steps on your book, but it is just not working...
    Thanks in advance.

    Best Regards
    Miguel Veloso

    ReplyDelete

More of my books