09-24-2020, 04:59 AM | #1 |
Connoisseur
Posts: 98
Karma: 10
Join Date: Jul 2020
Device: The (orly) amazing Kindle Oasis 3
|
KOReader and Fonts
Hello KOReader readers.
I would like to learn something about font management in KOReader. For example, I would like to use "Vollkorn". http://vollkorn-typeface.com/ http://vollkorn-typeface.com/downloa...korn-4-105.zip in the TTF folder of the zip file are the following files: Code:
Vollkorn-Black.ttf Vollkorn-BlackItalic.ttf Vollkorn-Bold.ttf Vollkorn-BoldItalic.ttf Vollkorn-ExtraBold.ttf Vollkorn-ExtraBoldItalic.ttf Vollkorn-Italic.ttf Vollkorn-Medium.ttf Vollkorn-MediumItalic.ttf Vollkorn-Regular.ttf Vollkorn-SemiBold.ttf Vollkorn-SemiBoldItalic.ttf I have created the folder /koreader/fonts/vollkorn. How do I name the files? Or should KOReader automatically recognize regular, bold, italic etc.? https://github.com/koreader/koreader/wiki/Fonts Does not answer the questiion |
09-24-2020, 05:08 AM | #2 |
Member
Posts: 11
Karma: 10
Join Date: Jan 2019
Device: PW4, tolino epos 2
|
They should be recognized if you copy them into the koreader/fonts directory without subdirectory.
|
Advert | |
|
09-24-2020, 06:45 AM | #3 |
Connoisseur
Posts: 98
Karma: 10
Join Date: Jul 2020
Device: The (orly) amazing Kindle Oasis 3
|
They can also be in folders, does not matter. See also the readme.md in the /koreader/fonts folder.
The question is rather about the naming. If I copy all files into one folder superbold will be activated automatically. If I then select bold in KOReader, the font becomes a little bit thinner. If I have only "Vollkorn-Regular.ttf" in the folder, the font is displayed normally. |
09-24-2020, 08:15 AM | #4 |
BLAM!
Posts: 13,492
Karma: 26047188
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Substyles are not supported. Only the four standard ones are.
So, generally, you'll want Regular, Bold, Italic & BoldItalic. You *might* be able to actually use a different "base" weight (i.e., Thin or Medium instead of Regular), but it *might* require mangling the metadata and/or filenames. ---- What currently happens is that CRe walks over your folder in inode order, finds the first 4 fonts in a matching family, tries to figure out which is which (and generally fails for !Regular base weights), and calls it a day. Since, instead of 4 exact styles, you have a crapload of stuff in there, you get a "controlled" random result ^^. Check your crash.log, it'll be spouting quite a few warnings about discarding fonts. Last edited by NiLuJe; 09-24-2020 at 08:19 AM. |
09-24-2020, 04:37 PM | #5 |
BLAM!
Posts: 13,492
Karma: 26047188
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Much nicer recap of my half-assed "you might be able to do that" answer, thanks to @poire-z:
https://github.com/koreader/koreader...ment-698520071 |
Advert | |
|
09-27-2020, 02:17 AM | #6 |
Connoisseur
Posts: 98
Karma: 10
Join Date: Jul 2020
Device: The (orly) amazing Kindle Oasis 3
|
Thank you very much, and to poire-z of course!!!. I now only have four files in the folder /koreader/fonts/vollkorn:
Code:
Vollkorn-Bold.ttf Vollkorn-BoldItalic.ttf Vollkorn-Italic.ttf Vollkorn-Regular.ttf How works bold, italic... if only the "regular" file is there? Is it calculated by KOReader from regular and is it more accurate with the corresponding files? |
10-01-2020, 10:01 AM | #7 |
Incanus
Posts: 275
Karma: 210
Join Date: Oct 2017
Location: Chile
Device: Boyue Likebook T80D
|
I've tried and checked many times: the only file needed is the -regular one.
KO Reader works out the bold, italic and bold+italic by itself. Kind regards Enviado desde mi SM-G950F mediante Tapatalk Last edited by Incanus; 10-03-2020 at 07:30 AM. |
10-02-2020, 10:54 AM | #8 | |
Connoisseur
Posts: 98
Karma: 10
Join Date: Jul 2020
Device: The (orly) amazing Kindle Oasis 3
|
Quote:
Written with my Computer. |
|
10-02-2020, 11:01 AM | #9 |
BLAM!
Posts: 13,492
Karma: 26047188
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
@Winkelschraube: I have no idea what @Icanus is trying to say.
The post from @poire-z I linked to, on the other hand, is *definitely* canonical. |
10-03-2020, 07:37 AM | #10 |
Incanus
Posts: 275
Karma: 210
Join Date: Oct 2017
Location: Chile
Device: Boyue Likebook T80D
|
I put a <font name>-Regular.ttf file on the koreader/fonts/ directory.
After that, I restart KO Reader and it will show the <font name> font as an available font. If I selected and if the text has them, KO Reader will properly display the different styles, using only the <font name>-Regular.ttf file. Best regards Enviado desde mi SM-P350 mediante Tapatalk |
10-03-2020, 07:49 AM | #11 |
BLAM!
Posts: 13,492
Karma: 26047188
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Yes, that's synthesized Bold & Italic.
Which doesn't have much to do with what @Winkelschraube was asking . |
10-04-2020, 11:23 AM | #12 |
Connoisseur
Posts: 98
Karma: 10
Join Date: Jul 2020
Device: The (orly) amazing Kindle Oasis 3
|
But that is what I meant in my last question. (09-27-2020, 06:17 AM and 10-02-2020, 02:54 PM)
|
10-04-2020, 12:54 PM | #13 |
BLAM!
Posts: 13,492
Karma: 26047188
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
|
10-04-2020, 02:28 PM | #14 |
Connoisseur
Posts: 98
Karma: 10
Join Date: Jul 2020
Device: The (orly) amazing Kindle Oasis 3
|
Is there a way to find out if the file "fontname-bold" is used or if the bold is calculated by "fontname-regular"?
|
10-04-2020, 04:09 PM | #15 |
BLAM!
Posts: 13,492
Karma: 26047188
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
|
Check the logs, if it's not rejected, it's being used.
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Starting KOReader from CC works only if KOReader was not running before | Norbi24 | KOReader | 7 | 09-24-2020 12:10 PM |
KOReader en français / KOReader in french | cramoisi | Software | 33 | 04-04-2020 12:14 PM |
What are the nicest looking fonts you think would look good on the koreader? | lori87 | KOReader | 32 | 06-20-2019 08:14 PM |
KoReader - fonts | BobC | KOReader | 4 | 01-04-2019 05:29 AM |
How to add alternate fonts without replacing system fonts.(this time this is a guide) | techiemonkey | Kindle Developer's Corner | 17 | 09-12-2012 04:55 PM |