Quote:
Originally Posted by theducks
I think the OP is doing everything from the command line.
|
A couple of message back, Kovid Goyal suggested running a GUI conversion and looking at the log from that to see what values the level1 to level3 settings were using.
The problem I see with that is that after the conversion, the OP was opening the ebook in calibre's ebook-editor, deleting the ToC generated in the GUI mode conversion and using the ebook-editor to recreate it with "
Generate ToC from all headings" button.
I suspect that the OP might be able to do this by playing with the XPath for the levels so any h? tag would be used to create a ToC entry. Something like //*[name()='h1' or name()='h2' or name()='h3' or name()='h4' or name()='h5' or name()='h6'] though I haven't played enough with XPath to feel comfortable making recommendations.