Saturday, 28 July 2012

Formatting Your E-Book (Yourself)

Kindle Direct Publishing prides itself on the variety of formats it can now convert to a .mobi file: According to its FAQ, you can upload Word, HTML, Plain Text, Rich Text Format, and PDF files directly for conversion (in addition to the standard .prc and .epub formats).

The rationale behind such a wide selection would seem to be convenience -- BUT, uploading in one of these formats would most likely result in a poorly-formatted book (especially if you upload Word or PDF files, since these have unique characters that are not recognized by a Kindle). That's why most writers opt to pay a professional to format their e-book for them...but why not learn how to format it yourself?

For most writers, writing is only a hobby -- they attend to their jobs in the day and have families to take care of at night -- so I understand if people feel the need to hire a professional in this circumstance.  Not all of us are tech savvy, and the whole process can be quite time-extensive. But if writing is your full-time job, you really have no excuse; it isn't that difficult (even if you consider yourself to be a computer illiterate).

Take me, for instance. I was completely clueless as to how to format an e-book, and I managed to figure it out and complete it in 5 days. And the main reason it took this long was because of the general lack of information online (the Mobipocket tutorial is a joke, and definitely not aimed at beginners). I had to search message boards for help and other lesser known sites for hours because every detail seemed to be in a foreign language.

Which brings me to this post: I'm going to make things easy for you, and put all the information you need in one place! And I'll make sure everything is described in simpler terms, for beginners. (You can thank me later). 


All you need to start formatting your book is the Publisher Edition of Mobipocket Creator (which you can download here). Once you have it installed, the dashboard will look like this:




Under "Import From Existing File", you'll notice you have the option to upload your book as a Word or PDF file. But like KDP, this will cause formatting problems. To avoid this, we need to open up the original book file in Word and save it as a "Web Page, Filtered". To do this, open up the Word document and select File > Save As > Under "Save As Type" select "Web Page, Filtered", like so:


NOTE: Before you  save it as a web page, it might be wise to make sure all of your chapter headings are formatted as Headers. This step is especially important if you plan to include a clickable table of contents with your e-book. To do this, highlight your chapter headings and select "Heading 1":





Once you have inserted your headings, you can save as a web page and open up Mobipocket Creator. Under "Import from Existing File" choose HTML document and upload the web page file. After a brief conversion, you'll be taken to the following interface:





The first thing you should click on is "Metadata" on the left sidebar. In this section, you'll see a whole bunch of options to fill in, but don't worry about it because most of these you will provide to Amazon (or whatever platform you are using). The eBook Title and the Author name are all you need to fill in. Once you've done that, scroll to the bottom and click update. If you're uploading to Amazon, don't worry about the Cover Image (for more on why, read my earlier post).


Next, you're going to want to make a Table of Contents (although it is entirely optional). If you remembered to format all your chapter headings as Headers before you saved as a web page, this step is really easy. Just click on "Table of Contents", and under "Tag Name" and "First Level", type "h1" (The HTML notation for "Heading 1", which is what you chose in Word to format your Chapter headings). It should look like this:





Click Update and then "Build" at the top right. You can preview your table of contents. All your chapter headings should appear as clickable links to the page in which each chapter begins. In the Mobipocket Emulator you can also survey your ebook document and check for any errors in the conversion process (chances are you'll find many -- which brings us to the editing process).


Click to go back to your "Publication Files", and click "Save" at the top just in case. Then click on your .html file and "Edit with HTML editor". This is where things might get a little intimidating. What you'll see is a bunch of scary looking code. I am not an HTML expert so I won't be able to help you with any complex problems, but what I can offer are solutions to the most common problems encountered:


Chapter Headings


By default, chapter headings are NOT bolded. You'll probably want to make them bold, otherwise, they'll look odd. To do this, scroll down the HTML code until you see /* Style Definitions */ (or you can press CTRL+F and type "Style Definitions" to get there faster). Under Style Definitions, paste the following code in to make your Chapter Headings bold:

h1      
        {color: #c33;
        background: none;
        font-weight: bold;
        text-align: left}


It should look like this:


Paragraph Indentations


I have this site to thank for this information. Basically, paragraphs are coded in HTML as a member of the p-class. This means that any code beginning with <p> and ending with </p> contains a paragraph inside. By default, all paragraphs are indented. If you want all paragraphs in your text to NOT be indented, paste the following code under "Style Definitions":

p {text-indent: 0; text-align: left}

This means that all members of the p-class (paragraphs) will not be indented and instead aligned left. Makes sense, right?

Now, if you still want your paragraphs to indent but want to target a specific paragraph to align left, you need to find the specific paragraph you are looking for. Try CTRL+F and type the first few words of the paragraph and it should pop up. You'll notice the text is enclosed in <p>, like so:


<p class="MsoNormal" align="center" style="margin-bottom:0in;margin-bottom:.0001pt;
text-align:center;line-height:normal;text-autospace:none"><span style="font-size:12.0pt;font-family:&quot;Times New Roman&quot;,&quot;serif&quot;">All work and no play make Jack a dull boy</span></p>


Here, the paragraph is "All work and no play make Jack a dull boy". If you want to make it so the paragraph aligns left, just find where it says "style=" and insert "text-indent: 0;" like so: 


<p class="MsoNormal" align="center" style="text-indent: 0; margin-bottom:0in;margin-bottom:.0001pt;
text-align:center;line-height:normal;text-autospace:none"><span style="font-size:12.0pt;font-family:&quot;Times New Roman&quot;,&quot;serif&quot;">All work and no play make Jack a dull boy</span></p>


(Don't forget the quotation mark at the beginning and the end of the style section!)



Page Breaks


If you want to add page breaks at specific points in your book, first paste the following code under "Style Definitions":

.break { page-break-before: always; }

Now all you have to do is find the paragraph or heading you want on a new page, and modify the class. In the case of our earlier example, instead of it reading <p class="MsoNormal", it will now read <p class="break":


<p class="break" align="center" style="text-indent: 0; margin-bottom:0in;margin-bottom:.0001pt;
text-align:center;line-height:normal;text-autospace:none"><span style="font-size:12.0pt;font-family:&quot;Times New Roman&quot;,&quot;serif&quot;">All work and no play make Jack a dull boy</span></p>



Line Breaks


There's nearly a 100% chance you will encounter an issue with line breaks. This is because, by default, when converted to .prc, all your text is crunched together. So if you had a page that looked like this in Word:


It will most likely look like this after being converted to .prc:










To add line breaks, you need to add <br /> after every paragraph or header in which you want the break to occur (If there is an easier way of doing this, please let me know). 


And there you have it! This should address your most common concerns, however, if you've read this and still feel like a professional is your best bet, then feel free to hire one. But be careful. You don't want this to happen to you.  

No comments:

Post a Comment