![]() |
#256 | |
Enthusiast
![]() Posts: 28
Karma: 10
Join Date: Jun 2013
Device: Kindle Paperwhite
|
Quote:
![]() |
|
![]() |
![]() |
![]() |
#257 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 71
Karma: 200092
Join Date: Mar 2014
Device: kindle pw1
|
Ok - this would only make sense with pre 5.4 FW on the PW1 (or older devices) - but wouldn't it be nice to map custom fonts to generic font families?
Generic font-families in CSS are - serif - mapped to Caecilia - sans-serif - mapped to Helvetica - cursive - no mapping - fantasy - no mapping - monospace - mapped to KindleBlackboxC So - afaik - not all generic font-families are supported on the Kindle. Lately in well-done ebooks the use of generic font-families seems more common. So you may have chapter headings with font-family="some embedded font",sans-serif, the main text with font-family=serif and some handwritten letters with font-family="a second embedded font",cursive. When you select Publisher Font with such a book you get the embedded font for the headings, Caecilia (arghh) for the main text and the second embedded font for the letters. When you de-select Publisher Font you get the whole text with the font ticked (font-family is ignored). I tried to add alias sections to the alternate.conf from the "fontconfig"-hack - but that didn't work for me. I'm not able to do all the usb-networking and scripting. But I can see browser-like settings for the mapping as a good thing. Perhaps even a hack for the default font the Kindle falls back on if - this would be Helvetica with FW 5.3.9 - there isn't a font-family set for the main text in the above mentioned example and Publisher Font is selected. Sadly can't do much more than make the suggestion. |
![]() |
![]() |
Advert | |
|
![]() |
#258 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@mandy314: Unfortunately, the KF8 renderer works in mysterious ways, so while doing this on fontconfig's side would be trivial (since it's basically what we're already doing for the supported families), there's no guarantee the renderer would actually honor everything as intended.
|
![]() |
![]() |
![]() |
#259 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 71
Karma: 200092
Join Date: Mar 2014
Device: kindle pw1
|
@NiLuJe
Thanks for the quick reply! As I said - alias sections in alternate.conf don't work. And I assumed that the Kindle local.conf is parsed after the alternate.conf. But alas .. For those who have books with nice embedded fonts for headings or other special text parts and with no embedded font or with generic font-family settings for the main text I see two options to get the most out of it (with PW1/FW 5.3.9): (1) remove all embedded fonts and add generic terms (like sans-serif, monospace etc) to the font-family for the special text elements With this you can select your font and still have monospaced chapter headings for instance. (2) add a font-family="Your fav font" at body level and make sure the setting isn't overridden on p level - use the family name as shown with the Kindle Aa Menu With this you can select Publisher Font, get all parts with embedded fonts and still have the main text rendered with your fav font. |
![]() |
![]() |
![]() |
#260 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@mandy314: Keep in mind that I was talking about my own stuff. I don't remember how bulletproof the fontconfig KUAL extension is, so YMMV if you're using that. The appropriate FC_DEBUG value & fc-match help figure these things out on fontconfig's side, but that leaves the mysteries of how the KF8 renderer actually honors those...
As for your examples, the mixed Publisher fonts thing can be handled safely with the fonts hack. Usually, the fallback is serif, and overriding that is safe. As for sans, the fallback override usually takes care of it. Last edited by NiLuJe; 10-19-2014 at 01:54 PM. |
![]() |
![]() |
Advert | |
|
![]() |
#261 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 71
Karma: 200092
Join Date: Mar 2014
Device: kindle pw1
|
@NiJuLe (and thanks again)
FYI After looking at your sources I got the font mapping working (with this in the alternate.cfg): Code:
<match target="pattern"> <test name="family"><string>serif</string></test> <edit name="family" mode="prepend" binding="strong"><string>MyFavSerifFont</string></edit> </match> <match target="pattern"> <test name="family"><string>sans-serif</string></test> <edit name="family" mode="prepend" binding="strong"><string>MyFavSans-SerifFont</string></edit> </match> The "override" of the fallback font I found in your sources I'm reluctant to use - easier to edit the offending ebook. But I failed to persuade the Kindle to accept a binding/mapping of the font-families "cursive" / "fantasy" to any font - so another one for Calibre's EditBook feature. |
![]() |
![]() |
![]() |
#262 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@mandy314: If your device crashes when in USBMS mode, at least you'll know why ;p.
Yup, no idea how the KF8 renderer resolves those fancy family names... |
![]() |
![]() |
![]() |
#263 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Finally released v0.9.N, which, besides supporting the 'new' PW2 models, sports quite a few bugfixes and a few new features
![]() Last edited by NiLuJe; 10-31-2014 at 05:18 PM. |
![]() |
![]() |
![]() |
#264 |
Fervent Pleasure Seeker
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,224
Karma: 712073
Join Date: Feb 2009
Location: The Windmills of My Mind
Device: Clara HD
|
![]() |
![]() |
![]() |
![]() |
#265 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 63
Karma: 22712
Join Date: Jan 2013
Device: PW2
|
|
![]() |
![]() |
![]() |
#266 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@April_7th: No, it simply means that the hack is as functional as possible on those devices, like on the rest of the older PW2 variants.
|
![]() |
![]() |
![]() |
#267 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 63
Karma: 22712
Join Date: Jan 2013
Device: PW2
|
Thank you
|
![]() |
![]() |
![]() |
#268 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Nov 2014
Device: Kindle PW2
|
![]()
Hello!
I'm a bit of a noob at all of this. I just want to try some nicer fonts on my PW2, and things seemed to be going ok with the jailbreaking, KUAL etc. until I hit a wall. Basically, I've put some fonts into linkfonts/fonts, but they don't show up in the Font Overrides → [type] → Custom list. That list is just blank apart from the '/' options. If I go into the Amazon menu instead of Custom, I can see all the Amazon fonts there. I don't see any error when I use the 'Populate this menu' item. If it's any help, the font I'm trying to use is Crimson Text. I'm using a Mac and I'm familiar with command line stuff. Any ideas what I might be doing wrong? |
![]() |
![]() |
![]() |
#269 |
BLAM!
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 13,506
Karma: 26047202
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@caerphoto: Update the fontconfig cache first (there's a button in the Fonts meny, cf. the first post).
|
![]() |
![]() |
![]() |
#270 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Nov 2014
Device: Kindle PW2
|
I've tried that, still no luck
![]() |
![]() |
![]() |
![]() |
Tags |
fontconfig, fonts, freetype, hacks, paperwhite, touch |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
K5 FW 5.x ScreenSavers Hack | NiLuJe | Kindle Developer's Corner | 3036 | 06-23-2025 03:25 AM |
[Kindle Touch] Font Hack | ixtab | Kindle Developer's Corner | 508 | 05-18-2020 12:41 PM |
Hacks Kindle Touch Registration Hack | codeisnightmare | Amazon Kindle | 15 | 10-19-2014 09:17 PM |
Touch Can I get Kindle Touch Fonts On Nook Touch? | tanteoma | Barnes & Noble NOOK | 5 | 05-17-2012 09:02 PM |
Font Hack for Kindle Touch? | Sassapphras | Kindle Developer's Corner | 1 | 02-12-2012 09:05 PM |