View Single Post
Old 12-08-2012, 04:41 AM   #38
davidfor
Wizard
davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.davidfor ought to be getting tired of karma fortunes by now.
 
Posts: 4,245
Karma: 3677992
Join Date: Jul 2011
Location: Australia
Device: Kobo Touch, Kobo Glo
Arrow

Quote:
Originally Posted by bob451 View Post
I get, fairly consistently, 24 lines/page from epubs with "line-height: 1.2" for <p, <div, <td and <h\d, plus "widows: 0" & "orphans: 0", in the CSS.

Without those CSS entries for line-height, and with "readingLineHeight=1.2" in the .conf file, I get 23 lines/page. Explain that.
From some experiments, it looks like the minimum line height setting in the file or content_settings table is about 1.225. But, if the line height is set in the epub, it can be whatever you want.

I tested this by creating an epub with the following in it:
Code:
  <p>1<br />
  2<br />
  3<br />
  4<br /></p>
Except that it went to 40. I then made four copies and the numbers 1 to 5 in the titles. Then I put them on my Touch. After that I created the five entries in the content_settings table for the books. The font was set to Georgia, size 17 with margins of zero. I then played with different numbers in the line height setting. Then I disconnect the device and looked at each book and recorded the last number displayed. After a bit of playing, I got:

Code:
1.2	        32
1.225	32
1.25	        31
1.275	30
The first number is the line height, the second is the last number displayed on the page. Any number less than 1.225 gave 32 lines.

Then I edited a couple of the files and added line heights to the CSS. I tired 1.0 and 0.1. 1.0 put all 40 lines on the screen. 0.1 did as well, but they overlapped and covered less than a quarter of the screen.
Quote:
Where I don't consistently get 24 lines/page is for "long" paragraphs, that is, any paragraph of more than about 300 words.
I haven't tried anything with very long paragraphs, so have no suggestions. But, reading this has mad me flashback to having to read "Washington Square" in high school. The book had the smallest font for a novel I have ever read and had a lot of paragraphs that were more than a page long. It was the most boring and hard to read book I have ever read. I'm not sure if I ever manage more than a page in one sitting.
davidfor is offline   Reply With Quote