View Full Version : Serif, and sans-serif fonts


SamL
07-21-2011, 01:16 PM
So I don't embed fonts in my epubs, because I feel like most readers ignore them anyways.

Instead I try and keep it simple, and get it down to either serif or sans-serif, with maybe one preferred font.

Something like this:

font-family: "Times New Roman", serif;

font-family: "Arial", sans-serif;


But what I've noticed is that not even these really come through. On devices like the iPad or Nook, it just completely ignores all my preferences on which font to use.

I have chapters where everything is in serif, except captions and the subtitle, but on my devices it just spits them all out as serif. On the Nook I can get it to work if I turn on the publisher's settings, but shouldn't these readers be using the fonts I recommend anyways?

charleski
07-21-2011, 01:54 PM
This is exactly why ereaders shouldn't monkey around trying to alter the display parameters so that the users can choose to read everything in Comic Sans with a 5em line height.

You can apparently force the iPad to use fonts properly using the method described here (http://www.pigsgourdsandwikis.com/2011/04/embedding-fonts-in-epub-ipad-iphone-and.html) - i.e. you need to add a nonstandard file containing non-standard code in order to get iBooks to respect part of the standard.

ATimson
07-21-2011, 05:05 PM
On the Nook I can get it to work if I turn on the publisher's settings, but shouldn't these readers be using the fonts I recommend anyways?
That's the point of the Use Publisher Settings checkbox - checking that follows the CSS in the book, otherwise it lets the user's settings win.

SamL
07-21-2011, 05:50 PM
That's the point of the Use Publisher Settings checkbox - checking that follows the CSS in the book, otherwise it lets the user's settings win.

I get that, but the nook is the only reader I've seen that has that setting at all. And it will still follow the CSS you have in your book in terms of spacing, bold, font-size etc, except for serif/sans-serif aspect.

ATimson
07-21-2011, 05:53 PM
I get that, but the nook is the only reader I've seen that has that setting at all. And it will still follow the CSS you have in your book in terms of spacing, bold, font-size etc, except for serif/sans-serif aspect.
And margins. Also - if you use a fixed point size, I suspect (though I haven't tried this) that it'll ignore your fonts, and that it only obeys relative sizes without them.

Anyways, I don't know about other hardware readers, but I've seen it in other software ones on iPhone - both RMSDK (Bluefire) and not (Kobo, Stanza). Personally, I think that letting the reader's preferences win is a good thing; book creators don't always know better than me. :thumbsup:

Adjust
07-21-2011, 06:00 PM
Yeah it's a real pain in the ... to get sans-serif fonts working in iBooks...

You have to wrap the text in <samp>text goes here</samp> code...Luckily though you can do a find and replace for it...

Find
<p class="example">(.*?)</p>
replace
<p class="example"><samp>\1</samp></p>