View Single Post
Old 02-26-2012, 01:05 PM   #1
paulfiera
Addict
paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.paulfiera could sell banana peel slippers to a Deveel.
 
paulfiera's Avatar
 
Posts: 387
Karma: 3102
Join Date: Dec 2010
Location: EU
Device: Kobo Aura ONE, Kobo Libra H20
Embedded fonts and inline style

Whenever I have some epubs with embedded fonts I usually run the Modify epub plugin to remove them and then I do a conversion.

Doing that, the resulting epub always generates an inline style with these font definitions:

Quote:
@font-face {
font-family: "Charis";
font-style: normal;
font-weight: normal;
src: url(fonts/CharisSILR.ttf)
}
@font-face {
font-family: "Charis";
font-style: normal;
font-weight: bold;
src: url(fonts/CharisSILB.ttf)
}
@font-face {
font-family: "Charis";
font-style: italic;
font-weight: normal;
src: url(fonts/CharisSILI.ttf)
}
@font-face {
font-family: "Charis";
font-style: italic;
font-weight: bold;
src: url(fonts/CharisSILBI.ttf)
}
Then I open the epub in Sigil and replace all these occurrences.

I've tried checking the checkbox "fonts" in Look & Feel -> Filter Style Information hoping that no fonts would be declared in the inline CSS but that doesn't seem to do the trick.

Is there any way I can prevent calibre to declare these non existing fonts?

Not really a show stopper. Mostly so I can avoid doing the search & replace with Sigil after a conversion.
paulfiera is offline   Reply With Quote