View Single Post
Old 01-02-2011, 06:24 PM   #238
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 6,257
Karma: 16544692
Join Date: Sep 2009
Location: UK
Device: ClaraHD, Forma, Libra2, Clara2E, LibraCol, PBTouchHD3
The problem you have with this file is that there are font-family statements at a "lower level" than body or body.calibre.

You should be able to correct the already-converted epub by amending the epub's css file in Sigil or with Tweak-epub in calibre (whatever you're comfortable with). Given the settings in your @font-face statements, there is more than one way to fix this but the following 2 steps should work:

1. Change all those instances of
Code:
font-family: "Times New Roman";
to
Code:
font-family: serif; (or font-family: "Liberation";)
and all those instances of
Code:
font-family: Arial;
to
Code:
font-family: sans-serif;  (or font-family: serif; or font-family: "Liberation";)
I don't want to confuse you but I feel I should also add that the above could also have been achieved via the original Calibre conversion to EPUB if the Calibre ExtraCSS had matched your source file. I can't see the source file so I can't tell you what it should have been. If you want to pursue this for future info, send me a PM and we can take it from there.
2. You also need to make sure your actual font files are in exactly the correct directory as specified in your @font-face statements. e.g. you have referred to the Regular serif font as
Code:
res:///Data/fonts/LiberationSerif-Regular.ttf
which means that looking at your Sony in your PC's file browser you should have a directory
Code:
[Drive:]/fonts
containing the file
Code:
LiberationSerif-Regular.ttf
Everything is case-sensitive so directory names, filenames and extensions must match EXACTLY.

Last edited by jackie_w; 01-02-2011 at 06:28 PM.
jackie_w is offline   Reply With Quote