View Single Post
Old 01-10-2015, 07:04 PM   #122
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
When the line spacing is low enough that the descenders of one line start to overlap the ascenders of the line below, there is no way to draw a boundary line between the two lines of text without it including some of the upper line in the lower one or vice versa.

The kepub reader seems to be rendering all the lines of a paragraph first, and then choosing where to break the page afterwards, and so when the lines overlap there is no way to break the page cleanly in the middle of a paragraph. The result is that the bottom part of the last line appears at the top of the next page, and vice versa.

The epub reader must be using a smarter method where it calculates how many lines to render on each page before actually rendering them, as it doesn't have this problem.

If this is right, then there will be no way to avoid the problem in kepubs except to increase the line spacing until no part of successive lines overlap, but the minimum line spacing to use will depend on the font family.

Edit: I haven't tested, but I expect the same problem will happen in kepubs with the unpatched firmware if the line-height is set below a certain value in the book's stylesheet. If so then perhaps this could be reported to Kobo as a bug.

Last edited by GeoffR; 01-10-2015 at 07:51 PM.
GeoffR is offline   Reply With Quote