Hi !
I’ve played around with iBooks and font-family too.
iBooks doesn’t like to respect your font-family or text-align rules in all p, span and div. Exception : if there are other things in these elements, like span (even empty span…) or images, then the fonts work…
Just read these posts :
http://www.pigsgourdsandwikis.com/20...s-strikes.html
http://web.me.com/david.mundie/Linde...Revisited.html
http://web.me.com/david.mundie/Linde...in_iBooks.html
And here is what Liz Castro is writing in her book, Epub straight to the point :
Quote:
Apple inexplicably crippled font support in iBooks 1.1. While iBooks is perfectly capable of displaying the more than 30 font faces that are pre-installed on the iPad, Apple has for some reason kept iBooks from recognizing those fonts when applied to certain elements, namely: p, div, body, html, and span. On the other hand, iBooks has no problem understanding fonts applied to non-body text elements like headers (h1, h2, and so on), list items (li), definition lists (dl, dd, and dt), highlighted text (em, strong, b, i, code, and so on).
One way around this is to enclose body text in an additional non body-text element. For example, you could use a rarely used element like samp:
<p><samp>Even a criminal is entitled to fair play; and certainly when a man who has done no harm has been unjustly treated, he is privileged to do his best to right himself.</samp></p>
Then apply the desired font to the samp selector in the CSS:
samp {font-family: "American Typewriter";}
You’ll find updates on this issue on my website.
|