Quantcast
Channel: MobileRead Forums - Conversion
Viewing all articles
Browse latest Browse all 3919

@font-face is not embedded

$
0
0
Sorry for the 3rd similar topic, but I'm struggling with embedding the custom font for the whole day and even more.

Again tried to make the problem as simple as possible.

Right now I have the following simple thing and it doesn't work:

Code:

<!DOCTYPE html>
<html><head>
<meta charset="UTF-8">
<style>
@font-face {
    font-family: FontIcons;
    src: url(icons.otf) format("opentype");
    font-weight: 400;
    font-style: normal
}
</style>
</head>
<div style="font-family:FontIcons">!</div>
</body></html>

The browser shows it right, but epub does not get the font.

I convert it like:
Code:

ebook-convert /tmp/a/3.html 3.epub --embed-all-fonts  -vv

The output contains this:
Code:

...
Parsing 3.html ...
Added /tmp/a/icons.otf

But no message about "embedding" the font.

The 3.epub has the icons.otf file, but does not show up the font symbol.

The full example (html + css + epub) http://ilyakantor.ru/font.zip

Viewing all articles
Browse latest Browse all 3919