View Single Post
Old 10-12-2009, 10:22 PM   #4
user_none
Sigil & calibre developer
user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.user_none ought to be getting tired of karma fortunes by now.
 
user_none's Avatar
 
Posts: 2,487
Karma: 1063785
Join Date: Jan 2009
Location: Florida, USA
Device: Nook STR
Quote:
Originally Posted by p3aul
*exactly* how is the --markdown option used the skimpy user manual is not that clear.
Read about markdown here. Enable it in the TXT input conversion options in the GUI or use --markdown if you are using ebook-convert. Markdown itself is a simple syntax that allows for basic formatting of TXT files. When run though a markdown processor it turns those formatting identifies into equivalent HTML tags. E.G. # becomes h1, ## becomes h2.

Quote:
Originally Posted by p3aul
Even converting the text to html and making <h1> and <h2> tags is no use. The TOC is just never generated.

It used to be so simple to generate an ebook file. Why is it so complicated now?
Because of all the people complaining that they don't want a toc or their input file is structured in such a way that they need to be able to specify custom toc identifiers.

To get it working in your case, set the --level1-toc to "//*[name()='h1']" in the table of contents section to have it work. Use the same xpath with h2 and h3 for level 2 and 3 to get the sub items (## and ###).
user_none is offline   Reply With Quote