Buh-Bye, 2013–Howdy to the New Year

2013 was a helluva year. Lots of personal drama. Evacuated because of a fire, followed by months of malaise from the smoke because the entire state of Colorado was on fire. Massive rains and subsequent flooding that destroyed my basement. Far too many days spent at the hospital with my children and grandbaby. One thing after another and wondering, oh god, what’s next?

QuinnSeatBut 2013 was an amazing year, too. The Amazing Poop Machine is happy, healthy and growing fast. Everyone is healthy now. I got a promotion–Larry Block has dubbed me The Production Goddess. (I’m practicing how to work that into casual conversation.) I worked with some incredible writers this year: Thomas Pluck, Randall Wood, Jerrold Mundis, Julia R. Barrett, Robert Silverberg, Katherine O’Neal, William Arnold, Sharon Reamer, Carole Nomarhas, Chuck Dixon, Steven Ramirez, Penny Watson, Marina Bridges, and far too many others to list. (Heh. I always wanted a job where I am paid to read, and now I have it and it’s the best job ever!)

Burglar_Limited-XmasI took part in a project that tops my Best Of list for all time. Lawrence Block’s new novel, The Burglar Who Counted the Spoons, which he decided to self publish. From the first read of the manuscript to receiving the gorgeous hardcover limited edition in the mail, it was The Dream Job. I ended up producing four editions, including a print-on-demand Large Print edition. (You can find the ebook and trade paperback here and the special limited edition here.)

The best part of the year was learning new skills. I’ve learned tons and tons about ebook covers. (And bless you brave folks who have allowed me to do my on-the-job-training with your books!)

Cover montageI’ve learned to format fiction for CreateSpace print-on-demand editions. It’s way different than ebooks and a lot trickier, but it’s well worth the effort. (Pay no heed to the bald spots where I ripped out my hair in frustration. Heh.) At the risk of annoying the Hubris Gods, my book designs are pretty darned good.

pod montageIn the coming year, I’ll be stretching way beyond ebooks. I want to do concierge publishing for writers who’ve reclaimed their back lists and need to bring them back to life. I’d like to offer troubleshooting and production consulting for do-it-yourselfers. I can even do graphics for ebooks–wouldn’t your ebook look delicious with something fun like this for your chapter heads and title page?

titleSo buh-bye and sweet dreams to you, 2013. 2014 is here and it’s going to be a good one. I can feel it! And as a very special treat for all you writers out there, here it is, hot off the production line, available at CreateSpace, and soon available at Amazon and LB’s Book Store, the brand new print edition of Write For Your Life: The Home Seminar for Writers.

wfyl blog

Word to Calibre to MOBI: Part 3: File Conversion

You went through Part 1 and styled your Word file properly. In Part 2 you learned how to turn it into a functional html file. Now it is time to convert your file.

A caveat before we begin. I use Calibre, but I don’t really use it. It has a pleasant display and it’s a good way to double-check EPUB files I create. I don’t use it to convert my files. What I am about to show you is the result of some serious screwing around with the program. It’s a hack and it may not be the very best one. What it does is work. So, if any of you are more familiar with how Calibre works and you have a better way, feel free to share.

STEP 1: Open your html file in Calibre. It will convert into a “zip” file.

CAL16STEP 2: Convert the ebook into an EPUB file. (Yes, EPUB, not MOBI. You will never again use Calibre to convert MOBI files for commercial purposes. It’s still just fine for personal use.)

CAL17STEP 3: Once your book is converted and you are back at the main page, right click on the book title and a drop down menu will appear. There will be an entry that says “Edit Book.” Click that.

CAL18STEP 4: Holy Moley time again. It’s an EPUB editor.

CAL19STEP 5: In the left hand sidebar, under “Text” delete the file that says “titlepage.xhtml”

STEP 6: Under “Styles” open the file that says “page_styles.css”. It will contain some code that says:

{
margin-bottom: 5pt;
margin-top: 5pt
}

Delete that and Copy/Paste in its place this bit of code:

{margin: 0; padding: 0; border: 0; font-size: 100%; vertical-align: baseline;}
body {text-align: justify; line-height: 120%;}

STEP 7: Under “Images” will be your cover image. Open it. Now resize it. (make sure the Keep Aspect Ratio box is checked) Change the width to 800px. (The cover height should increase proportionately.)

STEP 8: Under “Miscellaneous” will be a file called “content.opf.” Open it. Scroll down to the bottom and you will see two entries: <guide> and </guide>. If you built your html file the same way as in this tutorial and deleted your titlepage.xhtml, there will be nothing in the guide.

CAL20Using Copy/Paste, insert this code between the two entries

<reference href=”FILE NAME” type=”toc” title=”Table of Contents” />
<reference href=”FILE NAME” type=”text” title=”Beginning” />

STEP 9: Figure out which of the files under “Text” is your table of contents. Copy the file name and paste it in the reference line so it replaces FILE NAME. (use Ctrl C to copy and Ctrl V to paste)

Do the same thing for whichever file (your title page or Chapter One or your preference for the beginning of your ebook) in the “Beginning” reference line.

Mine looks like this:

CAL21STEP 10: Save and close the EPUB editor.

STEP 11: Open the Kindle Previewer. Click on “Open Book” and select the EPUB file you just modified. If you did this right, you will get this box:

CAL22Now you have a MOBI file that will upload successfully at Amazon–and it will work. No squishy lines, no messed up formatting, and the user’s navigation guides will work.

I’m sure there are plenty of things you can do to modify the file in the EPUB editor. (I didn’t, for instance, even touch on the toc.ncx) This is a pretty rough hack I’ve come up with, and it can probably stand some streamlining. There is plenty of room for fine tuning. What I hope you see is that Word can be used for styling, but its html leaves far too much room for error in ebooks. With a little knowledge of html, you can write in Word, but then you do your styling in the text editor. When you’re comfortable with html, you can make complete ebooks and not have to use Calibre at all. (And you’ll be ready for Paul Salvette’s guide to ebook development, it’s featured in the sidebar.)

Again, you probably have plenty of questions. So send them to me at jayewmanus at gmail dot com and I’ll put together a FAQ post to answer them.

Word to Calibre to MOBI: Part 2: The html File

You finished Part 1 of this tutorial. Now on to Part 2. If you’re not familiar with html, what happens next is going to be freaky. But trust me, if you can copy/paste, you can do this.

NOTE: If your ebook is as simple as the one I’m using as an example, with no images and limited styles, you can stop right now and directly upload your Word file to Amazon. It will convert just fine and work well.

STEP 1: Do a Save As of your styled .doc file as an html file. It will look something like this:

CAL5Now you are done with Word.

STEP 2: Open your html file in Notepad++

Holy Moley! This is what it looks like?!?

CAL6CAL7STEP 3: Turn your special formatting tags into proper html tags

  • Italics <i> </i>
  • Bold <b> </b>
  • Underline <u> </u>

Easy to do with Find/Replace in Notepad++.

CAL8

Very important. ALL tags that are open must be closed. So if you have <i> for italics, then you must have </i> to close the tag. So use Find/Replace and make sure your numbers match up (Notepad++ will tell you how many items it replaced)

STEP 4 (Optional): Get rid of soft returns. Word has a nasty habit of inserting soft returns at the end of lines in paragraphs. In theory, they are meaningless. If you leave them in, they won’t affect your ebook very much. I have noticed, however, that they cause a wobbly quality to the justified text and some unusual behavior in line spacing. Not enough to affect reading quality, but enough to bug hyper-sensitive readers (like me). I prefer to remove them. If they bug you, too, let me know and I’ll show you how to use Find/Replace in Notepad++  to quickly remove them.

CAL9STEP 5: Get rid of the Section junk. If you styled your document the same way I did, you will have two lines of code–one at the beginning that says something like <div class=Section1> and a closing tag at the end of the document, </div>. They are extraneous. Delete them.

CAL11CAL10(by the way, if your Notepad++ file doesn’t look the same as mine, it’s because I have turned off word wrap and eliminated the extra soft returns)

STEP 6: Extract your styles. In my example there are three: MsoNormal, Center, and h1. Select them, copy them and paste them into a new text file.

This is what they look like. Comments in italics are mine.

h1
{mso-style-next:Normal; (Word junk, delete)
margin-top:48.0pt; (We are going to change this)
margin-right:0in;
margin-bottom:48.0pt;
margin-left:0in;
text-align:center;
page-break-before:always;
mso-pagination:none; (Word junk, delete)
mso-outline-level:1; (Word junk, Delete)
font-size:14.0pt; (We are going to change this)
mso-bidi-font-size:16.0pt; (Word junk, delete)
font-family:”Times New Roman”; (Delete)
mso-bidi-font-family:Arial; (Delete)
mso-font-kerning:0pt;} (Delete)

p.MsoNormal, li.MsoNormal, div.MsoNormal
{mso-style-parent:””; (Junk, Delete)
margin:0in; (Delete)
margin-bottom:.0001pt; (Delete)
text-indent:.3in; (Change)
mso-pagination:none; (Delete)
font-size:12.0pt; (Delete)
font-family:”Times New Roman”; (Delete)
mso-fareast-font-family:”Times New Roman”;} (Delete)

p.Center, li.Center, div.Center
{mso-style-name:Center; (Delete)
margin-top:6.0pt; (Change)
margin-right:0in;
margin-bottom:6.0pt;
margin-left:0in;
text-align:center;
mso-pagination:none; (Delete)
font-size:12.0pt; (Delete)
font-family:”Times New Roman”; (Delete)
mso-fareast-font-family:”Times New Roman”;} (Delete)

STEP 7: Modify the styles. The coding in an ebook is actually quite simple. The major bits for your css stylesheet are as follows and most are self-explanatory:

  • margin /This is the margin for each paragraph block. This controls the top, bottom, right and left
  • text-indent /This is for paragraph indents
  • font-size /Kindle books render in either “ems” or percentages. Converters do their best to recognize points (pts) and inches, but results are iffy. That is why we’re going to change them.
  • font-style /For italics
  • font-weight /For bold

We are going to keep this very, very simple. Because there will be some coding for the body text, you don’t need much in these paragraph styles. Basically, we will whittle and adjust so they look like this (feel free to copy/paste these):

p.MsoNormal
{text-indent: 1.4em;}

h1
{margin: 2em 0;
text-indent: 0;
text-align:center;
page-break-before:always;
font-size: 1.4em;
font-weight: bold;}

p.Center
{margin: 0.5em 0;
text-indent: 0;
text-align:center;}

If you want to play with the styling, go to the w3schools website. To know what works in a Kindle book, you can look at their “approved” list (which often seems to change on a whim).

STEP 8: Replace the header. Copy the text that follows:

<?xml version=”1.0″ encoding=”UTF-8″ ?>
<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.1//EN” “http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd&#8221; >
<html xmlns=”http://www.w3.org/1999/xhtml&#8221; xml:lang=”en” >
<head>
<meta http-equiv=”Content-Type” content=”application/xhtml+xml; charset=utf-8″ />
<title>BOOK TITLE</title>
<style>
/*===Reset===*/
html, body, div, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, acronym, address, code, del, dfn, img, ins, kbd, s, samp, small, strike, strong, sub, sup, tt, var, center, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, article, aside, canvas, details, embed, figure, figcaption, footer, header, hgroup, menu, nav, output, ruby, section, summary, time, mark, audio, video
{margin: 0; padding: 0; border: 0; font-size: 100%; vertical-align: baseline;}
body {text-align: justify; line-height: 120%;}

<!– Insert your paragraph styles here –>
</style>
</head>
<body>

Paste it in your file as follows:

CAL12New header and styles pasted in:

CAL14Step 9: In the menu bar in Notepad++ find Encoding and click it. In the drop down menu it will say: Convert to UTF-8 without BOM. Click that.

To see your styling live, in the menu bar you will see “Run.” Click it and in the drop down menu choose “Launch in (whatever browser you use)” Here is mine in Firefox:

CAL15See, that wasn’t so hard was it? Now you have a serviceable html file you can convert into an ebook. BUT, your job isn’t done quite yet. In Part 3 I’ll show you how to convert your file into a MOBI file that works.

_________________________________________

Styling ebooks isn’t difficult. Armed with only a few lines of code, you can create beautiful ebooks and some very interesting text effects. If anyone is having trouble getting their styles just right, feel free to email me–jayewmanus at gmail dot com–and I can probably come up with just the paragraph style you need.

 

 

Word to Calibre to MOBI: Part 1: Styling in Word

So, I’ve been obsessanating–again. In my last post I promised that there was a way to convert Word files in Calibre into ebooks that work perfectly on Kindles. That is true. It can be done. I was looking for a quick and dirty hack that worked every time. That is not possible.

Here’s the real problem. You got your indie writer who has put her heart and soul into writing her story. She’s not technical. She’s not a computer geek. She just wants readers to find and love her stories. Problem: How to get the story from Word onto a reader’s Kindle? Enter Calibre. Just save your Word file as an html file, load it into Calibre, convert it into a mobi file and upload it to Amazon. Done!

The problem with that? Calibre mobi files don’t quite work right when uploaded to Amazon. Period. They can work, at best, almost right. For the writer who’s eager to get back to writing her next story, that’s good enough.

As a reader, that attitude pisses me off. I buy and read a lot of ebooks. It pisses me off when the user preference controls don’t work. It pisses me off when I can’t navigate an ebook. (It’s not just indie publishers, folks. I get pissed off by the Big Pubs who can’t bother proofreading the ebooks and by the nastiness that turns up in ebooks built with InDesign, and don’t even get me started on the crap that happens when they turn scanned backlist books into ebooks.) A poorly produced ebook is equivalent to a writer using a mimeograph and newsprint, stapling the pages together and saying, “Here you go. That’ll be five bucks.” I’m insulted.

As an ebook producer, I get it. Amazon doesn’t make it easy. It’s next to impossible to break open a mobi file to tinker around in the code and fine tune it. Plus, as I explained before, Amazon has… quirks. They build their devices, then create the platforms, then play catch up with updates to older models, and it’s not easy keeping up.

NOTE: The last time I bitched about Calibre being the wrong tool, Calibre’s creator informed me that the “line-squish” problem could be solved by converting the ebooks into azw3. That works. Except… I didn’t explore far enough. Amazon rejects azw3 files, so they are useless for distribution through Amazon.

The easiest thing a writer can do to ensure having a perfect ebook to sell on Amazon is to hire someone who knows what they are doing. For any number of reasons, that isn’t always realistic. I’m a realist. Hence, this series of posts that will take you step-by-step through the process of turning a Word file into a commercial-quality ebook to sell on Amazon. The beauty of this is, you don’t really need to understand html or how ebooks work or anything technical at all. All you have to know is how to Copy/Paste.

Before you begin, you will need four–FOUR!–programs on your computer.

Microsoft Word
Notepad++
Calibre
Kindle Previewer

I assume since you are using Word, you have Word. The other three are freeware. A note about Word. You do not want to do this with .docx files. You want .doc files. Older versions of Word actually work a lot better for making ebooks than do later versions of Word.

Ready? Let’s begin.

PART 1: STYLING IN WORD

Step 1: Do a Save As so your original stays intact.

Step 2: Tag your special formatting (italics, bolding, underlining). A word about “special formatting.” This only applies to words or passages that are italicized, bolded and underlined in the body text. Such things as headers and sub-heads will be dealt with later.

Calibre1I use a simple tagging system for special formatting.

  • Italics: -STARTI- -ENDI-
  • Bold: -STARTB- -ENDB-
  • Underline: -STARTU- -ENDU-

STEP 3: Turn “manuscript” punctuation into “printer” punctuation.

  • “Curly” or “Smart” quotes, not straight quotes (and apostrophes). Do make sure your quote marks and apostrophes are turned in the proper direction–Word has a bad habit of reversing them.
  • Proper em dashes, not two hyphens or en dashes or spaced hyphens
  • Proper ellipses

STEP 4: Kill “soft” returns and tabs, and eliminate extra spaces

  • To turn “soft” returns into hard returns: In Find/Replace search for ^l (that’s a caret mark and lower case L) and replace with ^p (caret mark and lower case P)
  • To get rid of tabs: In Find/Replace, search for ^t (caret and lower case T) and replace with nothing
  • Don’t forget to get rid of extra spaces before and after paragraphs

STEP 5: Select all, copy and paste entire file into Notepad++

Calibre2Yes, that is what it looks like. That’s what it is supposed to look like. This is a straight text file.

STEP 6: Finish cleaning up the file

  • Delete blank lines
  • Tag scene breaks (I use ## because it is easy to find)
  • Search for and clean up special formatting tags. Word is very sloppy and you’ll find tags around empty spaces and jumping paragraphs and other untidiness.

STEP 7: Back in Word, open a New Document and set your Styles (I am going by the assumption that you know how to use style sheets in Word.) For the purposes of this tutorial, I used three styles for my ebook:

  • Normal (built in style in Word, modify as you wish)
  • Heading 1 (built in, also modified)
  • Center (user-defined style)

CAL1It doesn’t matter much what font you choose. Times New Roman is fine.

CAL2This will be used for your chapter heads. Again, font doesn’t matter much.

CAL3STEP 8: Apply the “Normal” style to the new document. Select all and copy the text file in Notepad++ and paste the entire document into Word

Calibre3STEP 9: Style the document.

  • Apply the Heading 1 style to all chapter/story headings
  • Apply the Center style to any text you want centered (in this case, I applied it to the scene break indicators, THE END and table of contents entries)

CAL4Calibre4STEP 10: Bookmark all your Heading 1 entries (Word automatically bookmarks Heading entries, but those will not transfer over so you need to insert bookmarks manually)

STEP 11: Link your bookmarks in the table of contents

That’s it for Part 1. Your document is now clean and styled and ready for Part 2: turning your .doc file into a proper html file.

_____________________________________

A word about styles. Like I said, for this tutorial I am using only three styles. You can use all sorts of styles to create visually pleasing ebooks–just remember one very important thing: Word is a program whose main purpose is to create print documents. What you see on the screen is pretty much what you will get on a sheet of paper, but it is not at all what you would get in an ebook. I suspect after you finish this full tutorial you will have a better understanding of how ebooks work and how Word works, and you will understand why it is so important to use style sheets religiously.

A word about questions. I know you have them. Let’s make them useful for everybody. If you have a question about this tutorial, especially if it is a “How do I do this…?” type of question, email it to me at

jayewmanus at gmail dot com

I’ll put together a post with questions and answers.

 

 

 

 

Calibre, Word and MOBI: A Tale of Three Programs

(Yes, I know, MOBI is not a program, but my blog, my headlines…)

Ever since I started blogging about ebooks, I’ve cautioned people against using Microsoft Word to format their ebooks. Not because Word is a bad program and not because it’s impossible to create ebooks with it. It’s because it’s the not quite right tool. Word’s strength lies in creating print documents or pdfs.

Recently, I’ve been cautioning people to not use Calibre to convert their Word files into MOBI files in order to sell them on Amazon. Not because Calibre is a bad program and not because it’s impossible to create MOBI files with it. It’s because it’s not quite the right tool. Calibre’s strength lies in managing a person’s digital library. It was not created to convert commercial ebook files.

EPUB files are not as troublesome as MOBI files. EPUB is EPUB is EPUB, and while each device has its own special way of rendering the file to fit the platform, the differences between devices aren’t big enough for most people to notice. A single EPUB file will work pretty much the same on a Nook as it does on an iPad.

Calibre is set up for optimum use with EPUB files. If a publisher converts a Word (html) file into an EPUB file using Calibre, then what they see there is pretty close to what a Nook or iPad reader will see.

This is not true with MOBI files. The reason is Amazon. You see, EPUB devices have evolved and changed and upgraded and gone the way all technology goes, ever upward and onward. But the device makers built the newer devices around the existing ebook platform. So an EPUB ebook formatted five years ago will work pretty much the same on a new iPad as it did on a first generation Nook. Amazon went bass-ackwards. They built the new devices then tinkered and recreated entirely new ebook platforms to fit the new devices. So a MOBI file being sold on Amazon isn’t just a MOBI file. It’s also a KF/8 file and an iOS file and an AZW3 file and god knows what else is there. I don’t quite get all the technical stuff. What I do get is that the same ebook can work fine on a Kindle Fire, but go to hell on a Paperwhite and look okay on a Kindle Keyboard and turn into gibberish if an iPad user gets hold of it.

The whys and wherefores don’t matter as much as the fact that a file formatted in a program which is optimal for printing documents and then converted with a program that is at its best with EPUB files, is going to have trouble meeting the very odd demands of Kindles.

(By the way, if you are using Scrivner or InDesign to create your ebooks for sale on Amazon, you will run into the same exact problems because Amazon is constantly tweaking and fiddling with the platform(s) and updating devices and they don’t necessarily share what they’ve done with the rest of the world.)

I realize that none of what I just wrote is going to dissuade people from using Calibre to convert their Word docs into MOBI files to sell on Amazon. I know this because people are using Word because that’s the program they know and love(hate) and they need a way to convert those Word files and Calibre is the shortest distance between A and B.

So instead of wagging my finger and clucking my tongue, I did some research. Question: Is it possible to format a file in Word and convert it with Calibre and create a MOBI file good enough to sell on Amazon? (Here, I make a very clear distinction. If your Nook died and you bought a Kindle, and you want to convert all your Nook books into MOBI files you can load onto your Kindle, Calibre is a great tool. That’s personal use. You expect that the ebook might not work completely right, but that’s okay, at least you have it. You can’t ask your paying customers to accept that standard.)

What I discovered is: Yes, it is possible.

I managed to fix the worst problems I see with Calibre-converted ebooks. I managed to create ebooks that respond properly to all the user preferences in three generations of Kindles (Kindle Keyboard, Paperwhite and Fire). I almost got Calibre to build a toc.ncx (what the user sees in the Go To features on Fires and Paperwhites) the way I want it to. I think with some more tinkering and fiddling around inside the opf file, I can fix that problem. I couldn’t get the cover to display on the bookshelf in my Paperwhite, but that’s kind of a non-issue, since Amazon will handle that when the book is uploaded. (It is only a big deal if a publisher is selling direct.)

Even though the ebooks I created this way aren’t up to my standards, they will respond to user preferences and they will look fine and read fine, and thus, they are good enough for uploading to Amazon.

There is a caveat. If you format your document, save it as an html file and convert it as is with Calibre, your ebook will be broken. It will be a substandard product you should not ask people to pay for. What you have to do first and foremost is format your Word file so it works within Calibre’s parameters, and secondly, you have to fix the html coding in the Word file.

Sound scary? It is, kind of. Word’s html coding is a nightmare, full of mso odd bits that give Kindles the hiccups. The good news is, all you really need to do is remove some very specific lines of code and rearrange a few others.

Since this post is running long and I don’t even have any pretty pictures to enliven it, (plus I have a buttload of Christmas gifts to wrap) I am going to explain how I did it in my next post. It’ll have pictures. In the meantime, if any of you, Dear Readers, have figured this out and feel like sharing in the comments, feel free.

A Holiday Gift for You: Ebook Ornaments

You’ve all been so nice to me this year, thought I’d give you a little gift. Here are some ornaments you can use in your ebooks for scene break indicators or chapter head ornaments. Just copy the images, rename them for your ebook files, and insert them.

Enjoy!

scroll

scroll

spots and dots

spots and dots

gradient line

gradient line

snowflake asterisks

snowflake asterisks

curved arrow

curved arrow

 

Are Your Ebooks Ready for the Holiday?

Baby BlogHidey ho, folks. Have you been busy? (NaNoMo, anybody?) I’ve been busy. So busy, in fact, that I am running on empty and it’s time to take a break. Part of the reason is pictured. (Say, howdy to the nice blog readers, Amazing Poop Machine.) Come December, I’ll be putting all my attention on projects for my posse (great stuff from Tom Pluck and Julia Barrett coming soon!), working on some personal projects, training minions, and spending lots of time with the family. I might even get this blog updated. New features coming in 2014.

That’s my roundabout way of saying, I have exactly three slots open until I shut down for the rest of the year. I won’t be taking on any new work after December 1 though January 1. So if you need your immortal words turned into a beautiful ebook in time for the Christmas rush, now’s the time to get them in.