public inbox archive for pandoc-discuss@googlegroups.com
 help / color / mirror / Atom feed
From: fiddlosopher <fiddlosopher-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
Subject: Re: EPUB toc for whole book?
Date: Thu, 25 Oct 2012 23:17:45 -0700 (PDT)	[thread overview]
Message-ID: <12953acb-5439-440f-86fd-918665b0f385@googlegroups.com> (raw)
In-Reply-To: <8cc0d96a-d364-4f03-a7bb-3b0b558fa857-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 1502 bytes --]

You'll be pleased to know that the dev version of pandoc does create a more 
full table of contents, so after the next release your script shouldn't be 
needed.

On Thursday, October 25, 2012 10:16:34 PM UTC-7, Jason Morrison wrote:
>
> I've written a Ruby script that post-processes the EPUB file to inject a 
> more full table of contents.  It includes h1 (chapter), h2 and h3 section 
> levels.
>
> I've pasted the script here: https://gist.github.com/e3158a3bba95b34ce9c0- it's pretty hacky, but does the job for me.
>
> My Haskell's not sufficiently up to snuff to include a patch to do this 
> properly, and I'm not sure there's a way to iterate over chapters+sections 
> in the templates (e.g. epub-titlepage.html).
>
> Also, in another thread, John @jgm asked for an example of an EPUB with 
> this kind of inline TOC, but I can't for the life of me find the thread/GH 
> issue.  Anyway, I included and an example before/after contents.opf and the 
> new contents.xhtml in the paste as well.
>

-- 
You received this message because you are subscribed to the Google Groups "pandoc-discuss" group.
To post to this group, send email to pandoc-discuss-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To unsubscribe from this group, send email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org
To view this discussion on the web visit https://groups.google.com/d/msg/pandoc-discuss/-/P_re1cppfJYJ.
For more options, visit https://groups.google.com/groups/opt_out.



[-- Attachment #2: Type: text/html, Size: 1987 bytes --]

      parent reply	other threads:[~2012-10-26  6:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-27 21:09 David Snopek
2012-04-28 10:21 ` niczero
2012-04-28 15:03   ` John MacFarlane
     [not found]     ` <20120428150316.GA405-nFAEphtLEs+AA6luYCgp0U1S2cYJDpTV9nwVQlTi/Pw@public.gmane.org>
2012-04-29 13:49       ` niczero
2012-04-29 16:31         ` John MacFarlane
     [not found]           ` <20120429163127.GC24897-nFAEphtLEs+AA6luYCgp0U1S2cYJDpTV9nwVQlTi/Pw@public.gmane.org>
2012-04-29 21:18             ` niczero
2012-04-29 21:37               ` John MacFarlane
2012-05-07 22:13       ` David Snopek
2012-10-26  5:16 ` Jason Morrison
     [not found]   ` <8cc0d96a-d364-4f03-a7bb-3b0b558fa857-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org>
2012-10-26  6:17     ` fiddlosopher [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=12953acb-5439-440f-86fd-918665b0f385@googlegroups.com \
    --to=fiddlosopher-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
    --cc=pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).