04-28-2013, 05:16 PM | #1 |
Addict
Posts: 254
Karma: 69786
Join Date: May 2006
Location: Oslo, Norway
Device: Kobo Aura, Sony PRS-650
|
List of epub formatting "don'ts"
In my library of 619 books, about 300 of which are retail productions, there are very few in which I haven't touched the code at all. Many changes I do are due to personal preference, for instance I prefer indented paragraphs to spacing. Some common formatting decisions, however, are just plain wrong, and should never be used in a straightforward novel for general consumption, because they will break rendering or functionality on some software and devices.
I'd like your help in compiling a short list of absolute don'ts when formatting epubs, with a short description of why this is a bad idea. I know there are a lot of epub tutorials out there, but the scope of this list is a lot smaller. Please contribute your viewpoints, also comment on mine if you feel that I'm mistaken. Please avoid points which vary with personal preference, I'm after the things that probably never should be done. I've also tried not to be too nitpicky, for such a list to have any value it shouldn't be too long. I'll start with a few points: * Don't use fixed units like in, pt, or px for anything. When text size is adjusted the spacing will often stay fixed. The 0.8in text-indent or 1.5in margins might look fine on your computer screen, but will look very silly on a phone. Use em for indents (I prefer 1.2em myself, but 1-2 em is acceptable). Use % or em for margins, or leave margins to the renderer defaults. This includes blockquotes. * Don't specify color for body text. Color:#000 might be detrimental to night reading modes on some readers. Also avoid grey, as it might render text almost unreadable on some e-ink screens, and usually adds little to the presentation. For charts and diagrams, don't rely on color to convey information, as it will be lost on b/w screens. * Don't adjust font size in body text. If you need other sizes for things like quotes or headings, use % or size names. Around 70% is the smallest text you should use, and only sparingly. * Don't adjust line-height. Leave it at default. Readers will render a sensible default, many can override it if desired, but a silly value here can make it difficult to hit the correct value if you adjust the view. Edit: One exception is in span styles for superscript, here a line height of 0 avoids extra spacing to the above line. * Don't use inline styling, or <style type="text/css"> in each html file. This makes your job of styling the epub more complicated, and is annoying to those of us who actually tweak our epubs ourselves. It might also break text resize on some ADE-based devices. Instead, put all your definitions in a css file. * Don't use any html/css whatsoever generated by MS Word. This should be obvious to anyone familiar with its output, but I still see a lot of mso-something styles and endlessly nested spans for no reason Some devices will choke on the overly complex and often invalid code. * Don't use empty paragraphs for spacing, or for indents. Specify the values in css. For section separators, consider inserting * * * or similar in it's own paragraph. Since you don't control where page breaks occur, a blank section separator might not always be apparent. I believe that this should be left as default - Man Eating Duck Last edited by Man Eating Duck; 05-08-2013 at 05:17 AM. Reason: Clarified inclusion criteria (must break rendering or functionality) |
04-28-2013, 05:22 PM | #2 |
Resident Curmudgeon
Posts: 75,858
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
* Don't use a line space between paragraphs as that causes the eye to have to stop and try to find the next paragraph plus, it just looks awful.
* Don't use margins that are huge. If you want margins so the text doesn't bump the edge of the screen, use 5-9pt (no need for a bottom margin) and in this case, it's OK to to use pt as you want the margins to always stay the same. Last edited by JSWolf; 04-28-2013 at 05:24 PM. |
04-28-2013, 05:36 PM | #3 | |
Addict
Posts: 254
Karma: 69786
Join Date: May 2006
Location: Oslo, Norway
Device: Kobo Aura, Sony PRS-650
|
Quote:
This also borders on personal preference, some people like a bit of space around the body text. I think it's best left as default. Since it's still a bad practice IMO (depending on the value of "huge"), I'll include it. Thanks! |
|
04-28-2013, 07:43 PM | #4 |
Resident Curmudgeon
Posts: 75,858
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
I've never actually tried the default margins. I shall give it a go and see what I get.
|
04-29-2013, 02:11 AM | #5 |
Wizard
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
|
Some of these I agree with, others not that much. I do believe in the credo 'less is more' in the e-book creating world, but I have very few 'must not' credos. I do use empty paragraphs though, because it is much easier to maintain for me. However, I only use it in the text itself, not for spacing around headers and so.
|
04-29-2013, 02:22 AM | #6 |
350 Hoarder
Posts: 3,574
Karma: 8281267
Join Date: Dec 2010
Location: Midwest USA
Device: Sony PRS-350, Kobo Glo & Glo HD, PW2
|
Two other things that bug me to no end:
* Don't use huge uncompressed images within the book or for the cover. Run them through a decent graphic program to compress them, if done properly, you will not see any difference on your reading device's screen. * Don't use a different image for each chapter for decorative purposes when the images are all identical. Use the same one image for all the chapters. |
04-29-2013, 02:53 AM | #7 | |
A Hairy Wizard
Posts: 3,182
Karma: 18843349
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
Quote:
- reduce the dimensions - reduce the color bit depth With Amazon and Apple (B&N ?) having a minimum dimension, that leaves reducing the bit depth. That affects the quality if the image. Is there some other process to compress images I'm missing?? +1 |
|
04-29-2013, 03:47 AM | #8 | |
350 Hoarder
Posts: 3,574
Karma: 8281267
Join Date: Dec 2010
Location: Midwest USA
Device: Sony PRS-350, Kobo Glo & Glo HD, PW2
|
Quote:
Here's an example I snagged off Amazon, both of these images are 24 bit, both are 643x1000 pixels. One is not compressed and is 392KB, the other is compressed and is 95KB. If I really scrutinize the images, I can pick up a few white flecks at the edges of the red lettering. And to me, for the size difference and as often as you look at a cover compared to the book, it's perfectly fine being compressed. I've seen much more drastic reduction in file size though on some images in purchased books. Totally unnecessary and it only serves to bloat the size of the epub. |
|
04-29-2013, 04:33 AM | #9 |
A Hairy Wizard
Posts: 3,182
Karma: 18843349
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
wow - one quarter the size!! That is impressive. I've been using photoshop but am nowhere close to an expert with the software. I've been saving with "high quality" .jpg about an 8. I thought that a lower quality number would change the bit-depth or something, so left it at 8. I'll have to play with those settings a bit. Thanks!
|
04-29-2013, 04:56 AM | #10 |
frumious Bandersnatch
Posts: 7,533
Karma: 19000001
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
|
Try saving any image as BMP (uncompressed) and PNG (at max, lossless compression). The image should look exactly the same, but typically the PNG one will be much smaller (especially if it's something with large single-color areas).
|
04-29-2013, 06:15 AM | #11 | |
Imperfect Perfectionist
Posts: 524
Karma: 863576
Join Date: Dec 2011
Location: Ølstykke, Denmark
Device: none
|
Quote:
IMHO it is usually not necessary to save in print quality for ebooks. Regards, Kim |
|
04-29-2013, 06:21 AM | #12 | |
Addict
Posts: 254
Karma: 69786
Join Date: May 2006
Location: Oslo, Norway
Device: Kobo Aura, Sony PRS-650
|
Quote:
I included this one not because it's "incorrect", but because they actually break on some devices (as in not being rendered). That counts as broken in my book, although in this case the devices in question are probably what's broken. |
|
04-29-2013, 06:31 AM | #13 | |
Addict
Posts: 254
Karma: 69786
Join Date: May 2006
Location: Oslo, Norway
Device: Kobo Aura, Sony PRS-650
|
Quote:
Last edited by Man Eating Duck; 04-29-2013 at 07:10 AM. |
|
04-29-2013, 08:04 AM | #14 | |
Wizard
Posts: 4,520
Karma: 121692313
Join Date: Oct 2009
Location: Heemskerk, NL
Device: PRS-T1, Kobo Touch, Kobo Aura
|
Quote:
For example inline styling can be fine to use in some cases. It can be that a standard stylesheet will not apply and you only have usage for 1 or 2 styles. Of course you can create a new/additional stylesheet, but if it is only for one page I would not mind an inline style. In general the cases you describe are valid and true, but not always. A few margins (page margins) can be in pt instead of em or percentages. I only create a small margin around my pages and I would not them to scale with font-size. It can break, because some readers will ignore the empty line if it is <p></p> or <p><br /></p>. However, all readers I know will honor <p> </p>. I know it is not always pretty or the best way to do it, but it will not break. |
|
04-29-2013, 08:24 PM | #15 | |
Resident Curmudgeon
Posts: 75,858
Karma: 134368292
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
Quote:
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Error: "can only concatenate list (not "unicode") to list" | bmuesse | Library Management | 2 | 01-11-2013 03:50 PM |
epub "padding left" to mobi "block quote" conversion issue | 1611mac | Conversion | 3 | 01-11-2012 02:10 PM |
Convertion error txt to epub "IndexError: list index out of range" | economix | Conversion | 6 | 12-25-2011 06:14 AM |
How to remove "Fully read" books from "Last Open" list? | pjeanetta | PocketBook | 4 | 12-08-2010 10:30 AM |
Suggestion: Don't set "color" tag in .epub css | McAlsop | Calibre | 16 | 06-17-2010 09:13 AM |