Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader

Notices

Reply
 
Thread Tools Search this Thread
Old 03-14-2016, 02:25 AM   #1
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 101
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
kepub font oddity

I noticed an odd problem after recently installing the KoboTouchExtended driver in Calibre and sending a book to the Aura H2O in kepub format.

The embedded font looks like its kerning is really messed up for punctuation.

Epub format:


Kepub format:


The font is EB Garamond and I only see this with kepub. The font is also loaded on the device, but with a kepub it can’t be selected - well you can select it as much as you like, but the font does not change.

Any ideas why this is so? I can’t see anything obviously different about the font.
Attached Thumbnails
Click image for larger version

Name:	screen_001.jpg
Views:	1245
Size:	106.3 KB
ID:	147101   Click image for larger version

Name:	screen_003.jpg
Views:	1266
Size:	93.4 KB
ID:	147102  

Last edited by seanos; 03-14-2016 at 10:27 PM.
seanos is offline   Reply With Quote
Old 03-14-2016, 02:56 AM   #2
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
I think what you are seeing might be because the ePub reader uses GPOS kerning, but the KePub reader uses old-style 'kern' tables for kerning.

Most fonts seem to come only with GPOS kerning tables. If you want the kerning to work with the KePub reader then you need to add old-style 'kern' tables to the font. You can use fontforge to add the missing tables. (i.e. so the font will have both GPOS and 'kern' tables, and it will then work with both ePub and KePub readers.)

Edit: Actually, on looking closer, the letters seem to be kerned okay in the KePub version, so I guess the 'kern' tables must be present. I have EB Garamond on my Glo (in ttf format with 'kern' tables added) and it doesn't have this problem though.

Edit2: I think if the font is embedded in the book then you won't be able to select a sideloaded font with the same name. Do you have a link to the actual version of the font you have embedded? It looks a little different to the EB Garamond I have. (EBGaramond-0.016.zip from https://bitbucket.org/georgd/eb-garamond/downloads.)

Last edited by GeoffR; 03-14-2016 at 04:24 AM.
GeoffR is offline   Reply With Quote
Advert
Old 03-14-2016, 07:15 AM   #3
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
What is interesting about the font you are using is that the KePub reader is displaying ligatures. With all the fonts I have seen, only the ePub reader displays ligatures.

The EBGaramond font I am using has the s_t and c_t ligatures in the font, but they are in the historical ligature set ('hlig' feature), not in the standard ligature set ('liga' feature), so they don't display automatically.

I wonder how your font's GSUB lookup tables are set out. Perhaps there is a way to make the KePub reader display ligatures for other fonts too, by editing the GSUB tables?
GeoffR is offline   Reply With Quote
Old 03-14-2016, 07:52 AM   #4
344a
Groupie
344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.344a ought to be getting tired of karma fortunes by now.
 
344a's Avatar
 
Posts: 188
Karma: 505964
Join Date: Feb 2016
Location: Hong Kong
Device: Hong Kong is done.
I just wonder how can you capture the screen?
344a is offline   Reply With Quote
Old 03-14-2016, 09:32 AM   #5
Dr. Drib
Grand Sorcerer
Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.Dr. Drib ought to be getting tired of karma fortunes by now.
 
Dr. Drib's Avatar
 
Posts: 44,748
Karma: 55645321
Join Date: Jan 2007
Location: Peru
Device: Kindle: Oasis 3, Voyage WiFi; Kobo: Libra 2, Aura One
Moderator Notice

seanos:
Please take a few moments to read our Posting Guidelines, in particular the part about the maximum image size allowed (600x600 pixels). Images that violate those guidelines will be deleted.

It is every member's responsibility to read our Posting Guidelines and follow them.

Thanks.
Dr. Drib is offline   Reply With Quote
Advert
Old 03-14-2016, 10:29 PM   #6
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 101
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
Quote:
Originally Posted by Dr. Drib View Post

seanos:
Please take a few moments to read our Posting Guidelines, in particular the part about the maximum image size allowed (600x600 pixels). Images that violate those guidelines will be deleted.

It is every member's responsibility to read our Posting Guidelines and follow them.

Thanks.
It would be nice if you didn’t delete text as well as the images. Since this is easily fixed a small grace period would’ve been nice as we don’t all live in the same hemisphere.
seanos is offline   Reply With Quote
Old 03-14-2016, 10:31 PM   #7
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 101
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
Quote:
Originally Posted by 344a View Post
I just wonder how can you capture the screen?
There is a setting you can change that makes the power button take a screenshot. While the setting is activated you can’t switch off using the power button though.

See this thread.
seanos is offline   Reply With Quote
Old 03-14-2016, 10:46 PM   #8
seanos
Zealot
seanos began at the beginning.
 
seanos's Avatar
 
Posts: 101
Karma: 12
Join Date: Apr 2010
Location: Melbourne, Australia
Device: Kobo Sage, Kobo Aura H2O, LG V20
Quote:
Originally Posted by GeoffR View Post
What is interesting about the font you are using is that the KePub reader is displaying ligatures. With all the fonts I have seen, only the ePub reader displays ligatures.

The EBGaramond font I am using has the s_t and c_t ligatures in the font, but they are in the historical ligature set ('hlig' feature), not in the standard ligature set ('liga' feature), so they don't display automatically.

I wonder how your font's GSUB lookup tables are set out. Perhaps there is a way to make the KePub reader display ligatures for other fonts too, by editing the GSUB tables?
I have run the font through FontSquirrel’s Webfont Generator which can fold OpenType features into the font (hlig in this case), so it’s possible that had done something strange along the way. It is odd that the problem only shows up in kepub though.

Although I have FontForge I’ve barely used it. Is it simply a matter of checking Old Style ‘kern’ in the font generation options? I notice there’s also a Windows-compatible ‘kern’ option — is that required as well? I had been using the OTF version.

I should probably go back and do some more testing.
seanos is offline   Reply With Quote
Old 03-15-2016, 01:30 AM   #9
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Quote:
Originally Posted by seanos View Post
I have run the font through FontSquirrel’s Webfont Generator which can fold OpenType features into the font (hlig in this case), so it’s possible that had done something strange along the way. It is odd that the problem only shows up in kepub though.
The ePub reader uses code in Adobe's RMSDK to render the fonts, but the KePub reader uses WebKit. They are very different, but in general the ePub reader handles fonts better than the KePub reader does. Things like kerning and ligatures work out-of-the-box with the ePub reader, but either don't work at all or take a lot of tweaking of the fonts to get them to work in the KePub reader. The KePub reader also has some problems with uneven word spacing and irregular line justification which might be related to its handling of fonts.

Possibly the Webfont generator has folded in some feature that the KePub reader can't handle properly, perhaps the opbd/lfbd/rtbd features? It is interesting though, it might still be possible to fold in the ligatures without the other features and get a font where ligatures work in the KePub reader.

Quote:
Although I have FontForge I’ve barely used it. Is it simply a matter of checking Old Style ‘kern’ in the font generation options? I notice there’s also a Windows-compatible ‘kern’ option — is that required as well? I had been using the OTF version.
Yes, to get the normal kerning working in the KePub reader just tick the Old Style 'kern' option. I haven't seen a WIndows-compatible option, but i am using an older version of FontForge. The Webfont generator might be doing something else with the kerning though, so maybe there are other ways to get the KePub kerning working.
GeoffR is offline   Reply With Quote
Old 03-15-2016, 02:42 AM   #10
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
One thing I just remembered about EB Garamond -- the KePub reader doesn't like the name for some reason, I had to use fontforge to change the family name from "EB Garamond 08" to "EB Garamond08" to make it work as a sideloaded font in the KePub reader.

Edit: Changing the font name to EBGaramondEight and the family name to EB Garamond Eight also works, so it seems to be the isolated numeral at the end of the name that it doesn't like.

Last edited by GeoffR; 03-15-2016 at 03:24 AM. Reason: Changing 08/12 to Eight/Twelve also works
GeoffR is offline   Reply With Quote
Old 03-15-2016, 07:40 AM   #11
drjd
The Couch Potato
drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.
 
drjd's Avatar
 
Posts: 34,509
Karma: 230999999
Join Date: Aug 2015
Device: Kobo Glo, Kobo Touch, Archos 9, Onyx Boox C67ML Carta
Quote:
Originally Posted by GeoffR View Post
One thing I just remembered about EB Garamond -- the KePub reader doesn't like the name for some reason, I had to use fontforge to change the family name from "EB Garamond 08" to "EB Garamond08" to make it work as a sideloaded font in the KePub reader.

Edit: Changing the font name to EBGaramondEight and the family name to EB Garamond Eight also works, so it seems to be the isolated numeral at the end of the name that it doesn't like.
Ah.. I have been struggling with this for quite some time. Thanks GeoffR, for the proper solution. Should I just rename the font files or to go through procedure using FontForge?
drjd is offline   Reply With Quote
Old 03-15-2016, 03:50 PM   #12
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Quote:
Originally Posted by drjd View Post
Ah.. I have been struggling with this for quite some time. Thanks GeoffR, for the proper solution. Should I just rename the font files or to go through procedure using FontForge?
You need to change the font's internal Family name (see attachment.)

If you just make the minimal change to remove the space before the final number in the Family Name, then you don't need to change the filename.

If you change the Fontname to EBGaramondTwelve-Regular and the Family Name to EB Garamond Twelve then the filename will need to change to match, but in that case FontForge should use the correct filename when it generates the new font.

(I also change the Name for Humans to match, but I'm not sure if that matters or not.)
Attached Thumbnails
Click image for larger version

Name:	fontforge.png
Views:	269
Size:	51.2 KB
ID:	147130  
GeoffR is offline   Reply With Quote
Old 03-16-2016, 02:22 AM   #13
drjd
The Couch Potato
drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.drjd ought to be getting tired of karma fortunes by now.
 
drjd's Avatar
 
Posts: 34,509
Karma: 230999999
Join Date: Aug 2015
Device: Kobo Glo, Kobo Touch, Archos 9, Onyx Boox C67ML Carta
Got it clear! Thanks.
drjd is offline   Reply With Quote
Old 03-16-2016, 05:04 AM   #14
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 74,037
Karma: 129333114
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
How does one add to the ligatures that RMDSK uses?
JSWolf is offline   Reply With Quote
Old 03-16-2016, 08:14 AM   #15
GeoffR
Wizard
GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.GeoffR ought to be getting tired of karma fortunes by now.
 
GeoffR's Avatar
 
Posts: 3,821
Karma: 19162882
Join Date: Nov 2012
Location: Te Riu-a-Māui
Device: Kobo Glo
Quote:
Originally Posted by JSWolf View Post
How does one add to the ligatures that RMDSK uses?
This is just what I have found by experimenting, there might be a better way:

The ePub reader seems to enable the 'liga' feature by default, so if you look in the GSUB lookup tables for a suitable 'liga' Standard Ligatures lookup subtable you can use "Edit Data" to add the ligatures you want.

If there are ligatures already present in 'hlig' or 'dlig' tables, then you can just edit the metadata for the table and change its feature to 'liga' to enable all the ligatures in the table; or else move individual ligatures from 'hlig' and 'dlig'' into a suitable 'liga' table.
Attached Thumbnails
Click image for larger version

Name:	GSUB.png
Views:	269
Size:	99.7 KB
ID:	147135  
GeoffR is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Smaller font size for kepub compared to epub on Kobo Aura HD yevgeny.bezman Kobo Reader 2 07-14-2015 12:16 PM
Aura HD Diferent font size in epub and kepub ersott Kobo Reader 24 04-15-2014 07:03 AM
Is there a way to import kepub to calibre/convert a kepub to other formats? Major General Library Management 9 04-08-2014 10:00 PM
Touch Sideloaded epubs-fixed the annotation with kepub but font resizing is not working PF4Mobile Kobo Reader 0 08-20-2011 09:09 PM
Oddity Gunnerp245 Calibre 8 11-14-2010 11:25 AM


All times are GMT -4. The time now is 11:00 PM.


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