Skip to content

Instantly share code, notes, and snippets.

@trauber
Last active December 13, 2015 19:38
Show Gist options
  • Save trauber/4964245 to your computer and use it in GitHub Desktop.
Save trauber/4964245 to your computer and use it in GitHub Desktop.
Paragraphs

Their importance will increase as the volume of non-paged literature increases. Style guides recommend using the paragraph in citations when possible. I'd like to collect links to software that provides paragraph counts for web documents and for e-reader documents. I'd also like to write some tools.

So far the only online documentation I can find about navigating within ebook documents is on Kindle's "locations." From what I read they amount to 128 bytes of data. It doesn't matter whether these bytes display on the page. So these are very arbitrary chunks, and their logical is not readily discernible or readable the way a section's, subsection's or paragraph's is.

I did find a bookmarklet for counting DOM elements and modified to provide paragraph counts (gist) . It is also possible to provide paragraph numbering with CSS (cribbed from stackoverflow article), (gist), (bl.ocks.org rendering). I have yet to figure out how to apply CSS in an epub or mobi file so that paragraph numbering can be displayed on an e-reader. I can only test .mobi files on a Kindle, since that's what I have. If my step daughter lets me (;P) I can test .epub files on her Nook.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment