bell notificationshomepageloginedit profileclubsdmBox

10% popularity   0 Reactions

To extend on Tom's answer I have to disagree with how the media type is written for Truetype and I would also like to show how its written for Opentype.
In the .opf file <manifest>:
Truetype fonts
<item id="Roboto_Regular" href="fonts/Roboto_Regular.ttf" media-type="application/x-font-ttf" />

media type for Truetype is: "application/x-font-ttf".
Opentype fonts
<item id="Roboto_Regular" href="fonts/Roboto_Regular.otf" media-type="application/vnd.ms-opentype" />
media type for Opentype should be: "application/vnd.ms-opentype" but I have seen "application/x-font-opentype" used and pass validation.
Prior versions of Epubcheck I want to say used to check for this but I haven't tested it within EpubCheck-3.0.1
Be careful on how you code your paths when declaring the src:url in the .css file for the font. I have seen some people use absolute paths when they should have used a relative path and it throw a validation error of an unused font.
Note you cannot just include a master .css file that calls for a ton of fonts. If you code for a font to be used in the .css file and include it in the package it must be used and declared in the .opf file or you will throw a:
<Error>
<Message>'fonts/foobar.ttf': referenced resource missing in the package.</Message>
<Line>2</Line>
<Column>71</Column>
<Resource>foobar.css</Resource>
<Class>com.adobe.common.ReportElement</Class>
</Error>

If you are not going to use the font you should remove it from the package and comment it out in the .css file


Free books android app tbrJar TBR JAR Read Free books online gutenberg


Load Full (0)

Login to follow story

More posts by @Phylliss

0 Comments

Sorted by latest first Latest Oldest Best

 

Back to top