View Full Version : Italic fonts dropping in epubs.


Lester.
08-24-2010, 08:50 AM
Hi, my name is Lester and I currently work for a London based book publishers and the task of converting the companies catalogue of books to various ebook formats has been given to me to do. I've been a Mac operator for the last 15 years, but only in the last 2-3 years I've got involved in ebooks.

I've recently discovered a big problem for us with our epub files with the italic fonts not displaying and only displaying the roman/regular version of that font. I don't think its down a particular font, as its happening to quite a few fonts. I'm using Indesign CS3 and CS5 to generate the epub files from. I've had a search around on Google and on here, but so far I haven't found a quick solution. The files I'm working on have already been printed at a printers, so the files I have are already laid out and formatted. Has anyone heard of this problem and would anyone have a possible solution?

Lexi Revellian
08-24-2010, 09:02 AM
With no specialist knowledge I prepared my novel for Smashwords and Kindle on my PC, and didn't have any problems with awol italics (I had other problems to iron out, due to the hidden formatting in Word).

Perhaps Word is easier for this task than InDesign? I'm not knowledgeable on this topic, but I'm sure others here are.

Lester.
08-24-2010, 09:55 AM
Thanks for the reply. I was trying to avoid putting the text in another program as I have about 500 books to do that are already laid out in Indesign. I would have to go through them all and reformat them if I was to copy out to another program.

st_albert
08-24-2010, 10:59 AM
I have exported quite a few books from ID4 to epub and have not had this problem. Are you also embedding fonts? (I don't.)

Without any data (such as sample code) I can't be much help other than to say that it should work.

You may find some helpful information in this thread:

http://www.mobileread.com/forums/showthread.php?t=94157

especially post # 13

Adjust
08-24-2010, 06:23 PM
Hi Lester,
I just send you a PM. Which I'm sure will fix your problem

Toxaris
08-25-2010, 03:51 AM
Perhaps something trivial, but what is the code that is used in the resulting epub for displaying italics? I usually use <em></em> and that works without a problem...

capidamonte
08-25-2010, 06:07 AM
Here's a link (http://www.creativepro.com/article/making-ebooks-indesign-part-1) to a two-part article on converting InDesign files to ePub.

The great-and-powerful Hitch shared it with me (even though I don't use InDesign.)

charleski
08-25-2010, 07:10 AM
Perhaps something trivial, but what is the code that is used in the resulting epub for displaying italics? I usually use <em></em> and that works without a problem...

If italics are applied as a local override (ie select the text and change the font to italic) then it wraps the text in a span:
span.no-style-override {
font-style: italic;
}

You have to make sure that local overrides are checked in the contents pane of the export panel, but that's usually done by default.

Lester, you need to take a look inside the epubs that are being created. Are the words meant to be in italic wrapped with a span? What is the css code for that span? My best guess is that this is a problem with partial font embedding due to the italic font not having the required permission bits. Turn off font embedding unless the books use a freely-embeddable font (you don't really want to get your publisher slapped with a lawsuit, so this is a good idea anyway).

WillAdams
08-25-2010, 09:20 AM
What fonts are involved? I'm suspecting that they're ancient old Type 1 fonts which used bizarre names --- I'd suggest re-setting the underlying character and paragraph styles (you did use styles pervasively, right?) and then using the Find Font panel to replace the remaining local formatting to nice OpenType fonts w/ sensible formatting.

Man Eating Duck
08-31-2010, 02:59 PM
If italics are applied as a local override (ie select the text and change the font to italic) then it wraps the text in a span:
span.no-style-override {
font-style: italic;
}

You have to make sure that local overrides are checked in the contents pane of the export panel, but that's usually done by default.
.

I tried to get the local overrides included from CS4, but found that in a lot of cases it didn't happen, or didn't show in some readers. A solution which works well for us is to apply character styles instead of local overrides, i.e. you create a style named italic which just specifies the font style "italic". Search and replace any instances of italics with the character style, and use Defined Styles instead of Local Formatting in the export. This also works for other local formatting such as bold, bold italics, superscript and so on.

I second your advice about font embedding. Sometimes you'll need to embed fonts for support for obscure glyphs, then you should go with a free one.