06-04-2023, 01:35 AM | #1 |
Member
Posts: 22
Karma: 10
Join Date: May 2022
Device: Kindle Scribe
|
The viewer's calculation of number of pages in a book?
I've been interested lately in figuring out how my ebooks' Kindle 'locations' would map to a number of physical pages in say a mass market paperback.
The location number doesn't change regardless of margin/font tweak etc. So there seems to be a few 'rough' ways to do it. For example, location x 23 to get total number of words, then divide by mass market paperback words per page so like 300. Anyhow, I noticed the other day that the Calibre e-book viewer can display the location in the book and (total?) pages in the footer in the lower right and it appears to be analogous to page number. Do we know how this is calculated? |
06-04-2023, 02:10 AM | #2 |
creator of calibre
Posts: 43,844
Karma: 22666666
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
The viewer is open source, you can read the code and see for yourself. IIRC it strips html tags takes a word count and divides by a fixed number of words per page.
|
Advert | |
|
06-04-2023, 03:58 PM | #3 |
Member
Posts: 22
Karma: 10
Join Date: May 2022
Device: Kindle Scribe
|
Thanks Kovid, I'm not a programmer but I was looking on GitHub to see if I could spy where the viewer's code lived, but wasn't seeing it.
|
Tags |
page numbering |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Number of pages in a book | albare | Kobo Reader | 14 | 01-28-2022 09:42 PM |
Show number of pages in book - where? | manawydan | Viewer | 2 | 08-06-2020 12:43 PM |
Page number in e-book viewer | Jim67 | Calibre | 2 | 01-29-2020 11:56 AM |
How does the calibre viewer calculate page number and total pages? | auspex | Development | 9 | 09-24-2014 08:10 AM |
Do the number of pages in an ebook differ from the number of pages in a physical book | Phoebemy | General Discussions | 12 | 07-19-2012 09:25 AM |