![]() |
#1 |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Months of Runaround From KDP Support: Font Embedding Fails...HELP!
I've been trying to get font embedding to work in my books (for KDP) for months with no success. KDP support has said "we're busy researching" or "you're doing it wrong, do it like we say"...
The problem is that from the VERY beginning I have done it the way they say to do it. They say that they "recently changed" how embedding is supposed to be specified, but that is how I have always done it, because the way Kindle handles it is to specify in CSS, which is exactly how it's done for epub. I create in Sigil, and upload and epub (with a couple of small format changes like the cover image being large and not declared as a separate html file and metadata switch to mobi format) to KDP. When the resultant file is produced, fonts have been completely stripped. (Confirmed using MobiUnpacker.) I have tried using different fonts, and different types of fonts. My files convert cleanly in Kindle Previewer (in Windows) and Calibre. The resultant mobi files, when uploaded to KDP, have the fonts stripped from them. I have spent literally weeks of work on this issue to no avail. I've tried dozens of different options of what type of font, which font, what converter I run a font through, etc. Nothing matters. I am at a complete loss as to why this is happening. I have slammed my head against the wall of KDP support for months, and am quite frankly left with 3 options. 1) ask here, 2) try and strike a deal with a "pro" to embed the fonts (I need literally no formatting, just the fonts to survive upload), or 3) chew my way further up the Amazon chain. So, as far as following the guidelines go, I have declared @font-face as Amazon recommends (the only place they talk about it is in their fixed-layout section, but relatively obviously, it's how you need to declare for a normal ebook as well. An example of how I am calling fonts in the books: (obviously in Styles\core-styles.css) @font-face { font-family : display-font; font-weight : normal; font-style: normal; src : url("../Fonts/display-font.ttf"); } As it should be, the .ttf, or .otf file I refer to is always contained in the Fonts directory. I have verified that these fonts are then absent in the files which come back from Amazon's KDP converter. (I have also attempted to remove the font-weight and font-style css elements to no avail. They don;t seem to make a difference one way or another for this issue.) When I call a font, I am doing so like this: p.toc-minor { font-family : display-font; text-indent: 0; margin: 0 0 0.2em 0; font-size: 125%; } The css styles are then called in the html files like so: <p class="toc-minor"><a href="../Text/TitlePage.xhtml">Title Page</a></p> This should result in a slightly larger than normal, unindented display font version of the words "Title Page" that has only a small bottom margin. That's in fact exactly what it does...everywhere but on the KDP-converted file. *** I appreciate any wisdom that anyone might possibly be able to share. I am an absolute perfectionist where it comes to getting things to display as well as possible cross-platform. I am attempting to follow the feel of the print version and make it so that ebook buyers at Amazon have an experience similar to those at Barnes & Noble or Kobo, or wherever. But at this point I am completely baffled by why I can format something perfectly (even using Amazon's own desktop software) and have it fail time and time again on upload. KDP support is convinced that my code is the problem. But if that's the case, they have yet to be able to point out exactly what I'm doing wrong. Maybe one of you can. |
![]() |
![]() |
![]() |
#2 |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Oh, and as a note: Sigil automagically declares fonts in relevant manifest section, so that's being handled. (Just in case someone thinks "hey, that needs to happen..." it has, just not hand-coded.)
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,334
Karma: 203719142
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
Exactly what version of the ebook are you "getting back" from KDP? And what do you view it with? If it's a MOBI-only version (and not the KF8 version), that would explain why the fonts are gone. MOBI doesn't support embedded fonts.
I ask because I have no idea how KDP works. |
![]() |
![]() |
![]() |
#4 | |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Quote:
![]() Thanks for the reply. I appreciate it! I am in fact referring to the KF8 half of the resultant .mobi file Amazon returns. In the version generated by Amazon's Kindle Previewer (which is their KindleGen with a GUI) I can use MobiUnpacker to verify that the fonts have been included in the appropriate location. But in the version I retrieve from Amazon after KDP has thrashed on it, those fonts have indeed been stripped. |
|
![]() |
![]() |
![]() |
#5 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,618
Karma: 8566337
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Quote:
Code:
@font-face { font-family : "display-font"; font-weight : normal; font-style: normal; src : url("../Fonts/display-font.ttf"); } Code:
p.toc-minor { font-family : "display-font"; text-indent: 0; margin: 0 0 0.2em 0; font-size: 125%; } Regards Rubén |
|
![]() |
![]() |
Advert | |
|
![]() |
#6 | |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Quote:
As far as the pointer, yes, it's fine. And the name should be irrelevant considering it's able to read all styles. Literally the only issue is the fonts. All the other CSS works perfectly. But thanks a ton for taking the time to offer suggestions. I really appreciate it! |
|
![]() |
![]() |
![]() |
#7 | |
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
P.S.: You are declaring the font-faces first in your stylesheet, right? Above everything else? And, where's your format declaration? (truetype or opentype?) And you're not using Type1's, right? Hitch Last edited by Hitch; 07-18-2013 at 04:11 AM. Reason: To add Question about placement and another ? |
|
![]() |
![]() |
![]() |
#8 | |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Quote:
The font faces are declared in the core-styles.css which is referenced by the html. They are right up at the top. They are not type 1s (I tossed a type one out, actually), and it does not matter if I use open type or true type as the results are the same (fonts stripped)... (I must note that I have alternating read posts by people who swear by one or the other, do you have a suggested type? converting is not a huge issue, after all.) All told I've tried about 10 fonts, multiple file formats of many of them, and none of survived. If you have a suggested font format (otf/ttf) I will certainly go from there as I continue to try and troubleshoot. But the Kindle Previewer does not throw a single warning on the fonts I'm working with currently, so I am at a loss as to why they're not making it through KDP. :/ I even tried specifying a body font on the off chance that KDP was requiring one before allowing header/display fonts to be used, but that didn't work. I am literally open to any suggestions or tips. Thanks a ton for replying! (P.S. I realized I missed answering one question. The fonts are in the manifest, of course.) Last edited by Mathew Reuther; 07-18-2013 at 04:27 AM. |
|
![]() |
![]() |
![]() |
#9 | |
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
The only thing I see, at all--and of course, none of us are looking at the actual ePUB--is that after your font calls, you don't have the actual type declaration, e.g.: Code:
src:url("../Fonts/OratorStd.otf") format("opentype"); Hitch |
|
![]() |
![]() |
![]() |
#10 |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Be as exacting as you'd like. I am not bothered at all. I was not aware that there was a (format) argument which could even be included. Is that something you typically use? I've never seen it laid out like that. Do you recommend using that format declaration as a standard in your css? (and what is the format declaration then for truetype? "truetype"?
As for the mainifest, here is an example of what they look like. This is, mind you, auto-generated by Sigil...I do not hand code it: (inside the manifest section of the content.opf file) <item href="Fonts/display-font.ttf" id="display-font.ttf" media-type="application/x-font-ttf" /> <item href="Fonts/header-font.otf" id="header-font.otf" media-type="application/vnd.ms-opentype" /> Now, as a test, if you could just tell me the name of a font or two that you know will work that come from a source that is free (fontsquirrel, dafont, google fonts, etc.) I can try to use those and see what happens. That way we know that the fonts themselves DO work in another file. Last edited by Mathew Reuther; 07-18-2013 at 07:56 PM. |
![]() |
![]() |
![]() |
#11 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,618
Karma: 8566337
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Quote:
![]() Code:
href="Fonts/display_font.ttf"
Code:
@font-face {
font-family : "display-font";
font-weight : normal;
font-style: normal;
src : url("../Fonts/display-font.ttf");
}
![]() It seems that here could be the cause of your troubles. Use "display_font.ttf" and "header_font.otf" for all declarations. Also, if neccesary, rename the fonts in your Fonts folder. Regards Rubén |
|
![]() |
![]() |
![]() |
#12 |
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
This is a typo/mismatch that is happening in this thread, not in the file. Thanks for noting it. I've corrected my latest post just for consistency.
![]() (In case it's not clear, I am using placeholder names for the fonts as the actual font names are not overly relevant...I have tried many different fonts, all with the same result. So I am looking at the entire thing as an abstract.) Last edited by Mathew Reuther; 07-18-2013 at 07:59 PM. |
![]() |
![]() |
![]() |
#13 | |
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
Those font declarations in the manifest look fine. Yes, in the CSS it's: format() with the one word type, either "opentype" or "truetype" in the parenthesis, replete with quotemarks. What's weird to me is that you say your fonts are surviving being Genned (KG or KP); they work in your ePUBs, but somehow, they're being stripped at the KDP. That's just bloody peculiar. This has been going on for months? You upload a working, functioning mobi with embedded fonts, and the preview is font-less? Man. That's ![]() Hitch |
|
![]() |
![]() |
![]() |
#14 | |||
SpecFic Writer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31
Karma: 20000
Join Date: Jan 2013
Location: Vista, CA
Device: Kindle Voyage, Kindle Fire, Nook, HTC One M8
|
Quote:
But I will give it a shot with some of the others. Thank you very much for giving me a sampling to work from. Quote:
Quote:
So, yeah... Facepalm indeed. And for the record, if it is useful, I am happy to hand the file off with some of these sample fonts (since we know they should work) just to see if touching the epub is useful. I really feel pretty awful talking to a professional formatter and basically begging for help, but the reason I have gone to the the time and effort of researching how to do this properly myself is because I believe that keeping the process in house is, in the long run, a much better option. (Assuming you can figure out how to do it right...which at this point it seems that I can't! Everything was going well until I wanted to take that one last little professional step and give the headers a bit to set them off by embedding fonts. Now, months later I am finally at the point of public begging for help. *sigh*) |
|||
![]() |
![]() |
![]() |
#15 | ||
Bookmaker & Cat Slave
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,503
Karma: 158448243
Join Date: Apr 2010
Location: Phoenix, AZ
Device: K2, iPad, KFire, PPW, Voyage, NookColor. 2 Droid, Oasis, Boox Note2
|
Quote:
Quote:
I assume you're using the latest KindleGen, and you said you'd even tried Calibre to AZW or whatever (K8 format) it is it makes, is that right? And that got stripped, also? Is that correct? Because if that's true, then it's definitely something in the ePUB. I mean, at least that narrows it down somewhat. And this is one book, or have you tried multiple books? (Again--just trying to narrow it down some). Hitch |
||
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Font Embedding? | teh603 | Writer2ePub | 75 | 01-08-2013 07:57 PM |
Font embedding | sachin | Sigil | 36 | 03-30-2012 03:26 AM |
Font embedding | sachin | Sigil | 3 | 03-21-2012 09:19 AM |
Do I need a font license if all I'm doing is referring to the font (not embedding)? | Stodder | Workshop | 21 | 04-21-2011 04:19 AM |
Special chararcters on the iPad or why does Apple not support Font-embedding? | georg3200 | ePub | 13 | 10-06-2010 10:32 AM |