Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > KOReader

Notices

Reply
 
Thread Tools Search this Thread
Old 12-31-2018, 12:58 PM   #1
BobC
Guru
BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.
 
Posts: 691
Karma: 3026110
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, (and HD),Energy Sistem EReader Pro +
KoReader - fonts

I have KoReader (2018- 12) running on a Kobo Glo. When displaying an EPUB document which has paragraphs declared as :

font-family : serif
font-family : sans-serif
and
font-family : monospace

I'm getting confusing results.

I have embedded fonts turned ON, the document does not have any fonts embedded in it - I am relying on the above generic font declarations.

The document displays correctly on other EPUB readers but in KoReader both the serif and sans-serif paragraphs display using the font selected in KoReader's menu. However the monospace paragraph displays in monospace irrespective of the menu selection.

Effectively this means that it's all or nothing for san-serif either the whole document (apart from monospace) is in serif or sans-serif.

If it wasn't for the monospace stuff displaying correctly I would think that KoReader didn't respect font-families within the EPUB, however it does handle that case.

Is this a known issue or a design decision ?

BobC

Last edited by BobC; 01-03-2019 at 01:06 PM. Reason: 3 instances of san-serif corrected to sans-serif.
BobC is offline   Reply With Quote
Old 01-03-2019, 12:54 PM   #2
Frenzie
Wizard
Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.Frenzie ought to be getting tired of karma fortunes by now.
 
Posts: 1,613
Karma: 724945
Join Date: Oct 2014
Location: Antwerp
Device: Kobo Aura H2O
If the san-serif typo stems from your original file, that might be the problem?
Frenzie is offline   Reply With Quote
Advert
Old 01-03-2019, 01:05 PM   #3
BobC
Guru
BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.
 
Posts: 691
Karma: 3026110
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, (and HD),Energy Sistem EReader Pro +
Well spotted - however it is just a typo in the posting; it's sans-serif in the css file.

It's as if the font selected in KOReader's settings is overriding that in the css EXCEPT when it's monospace.

BobC
BobC is offline   Reply With Quote
Old 01-03-2019, 02:43 PM   #4
NiLuJe
BLAM!
NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.NiLuJe ought to be getting tired of karma fortunes by now.
 
NiLuJe's Avatar
 
Posts: 13,477
Karma: 26012492
Join Date: Jun 2010
Location: Paris, France
Device: Kindle 2i, 3g, 4, 5w, PW, PW2, PW5; Kobo H2O, Forma, Elipsa, Sage, C2E
@poire-z helpfully reminded us of when we last discussed this: https://github.com/koreader/crengine/pull/216

TL;DR: Yes, there's no distinction between the sans & sans-serif generic names, by design. If you need one, embed fonts, and refer to those families explicitly.
NiLuJe is offline   Reply With Quote
Old 01-04-2019, 05:29 AM   #5
BobC
Guru
BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.BobC ought to be getting tired of karma fortunes by now.
 
Posts: 691
Karma: 3026110
Join Date: Dec 2008
Location: Lancashire, U.K.
Device: BeBook 1, BeBook Pure, Kobo Glo, (and HD),Energy Sistem EReader Pro +
Thanks for the helpful explanation. I find that I don't need to actually embed the font, simply change the css from

Code:
font-family : sans-serif;
to
Code:
font-family : FreeSans , sans-serif;
As the FreeSans font appears to be installed with KOReader.

BobC
BobC is offline   Reply With Quote
Advert
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
KOReader en français / KOReader in french cramoisi Software 33 04-04-2020 12:14 PM
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
An Observation on Fonts - Improving readability by using *bold* versions of fonts nesler General Discussions 12 06-24-2012 12:33 PM
Troubleshooting need the fonts in /usr/java/lib/fonts of kindle touch5.0.0 hanpal Amazon Kindle 0 02-20-2012 08:51 AM
Touch Fonts question (special characters in stock and custom fonts) levil Kobo Reader 20 09-23-2011 01:51 PM


All times are GMT -4. The time now is 02:30 AM.


MobileRead.com is a privately owned, operated and funded community.