View Single Post
Old 05-31-2013, 08:27 PM   #18
mattcurtis
Book Lover, Dev of Hyphen
mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.mattcurtis ought to be getting tired of karma fortunes by now.
 
mattcurtis's Avatar
 
Posts: 59
Karma: 2013886
Join Date: Apr 2013
Device: iPhone (Hyphen)
Quote:
Originally Posted by JSWolf View Post
I've already told you that the Count Pages Calibre plug-in has the code to do the ADE page count. You groaned that it's in Python. Did you forget that fast? You can look there and see how it's calculated.

ADE's method of pages uses a count of the text in the XML files. It does not matter what the CSS tells the XML how to display or what the user has set the font size to. The XML is a set file. Nothing the CSS does changes that. How it displays does not change the size of the file.
I'm still looking at its code, actually - it's been helpful, even though my Python sucks. I was asking for more information about the methodology so I can understand how to translate that into code that code into Obj-C/JavaScript (what I'm working with).

Secondly, if I'm not working with a compressed ePub, but an extracted one, does the same 1024 bytes apply?

Last edited by mattcurtis; 05-31-2013 at 09:25 PM.
mattcurtis is offline   Reply With Quote