View Single Post
Old 11-15-2010, 09:30 PM   #232
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,212
Karma: 16534894
Join Date: Sep 2009
Location: UK
Device: Kobo: KA1, ClaraHD, Forma, Libra2, Clara2E. PocketBook: TouchHD3
Quote:
Originally Posted by notsure View Post
How did you know to do that? I didn't see it listed anywhere.
Unfortunately there is no one way which always works. You have to look at the HTML and CSS inside the epub to decide what needs to go in ExtraCSS.

In your source epub each piece of HTML started with:
Code:
<body text="#000000" class="calibre">
rather than just plain
Code:
<body>
And the relevant bit of CSS contained:
Code:
.calibre {
    background-color: #fff;
    display: block;
    font-family: Times New Roman;
    font-size: 1em;
    font-weight: normal;
    line-height: normal;
    margin-bottom: 0;
    margin-left: 5pt;
    margin-right: 13pt;
    margin-top: 0;
    page-break-before: always;
    text-align: justify
    }

i.e. the font-family you needed to override was at a lower level than <body>. Hence, to replace "Times New Roman" with "Fontin" in the converted epub CSS you needed the ExtraCSS to specify
body.calibre {font-family: "Fontin", serif;}

[By the way, I know you didn't create the source epub, but for info, there should have been double quotes around the Times New Roman because it contained spaces.]

Last edited by jackie_w; 11-15-2010 at 09:32 PM.
jackie_w is offline   Reply With Quote