|
|
#1 |
|
Junior Member
![]() Posts: 2
Karma: 10
Join Date: Mar 2015
Device: iphone
|
Create TOC from non linear structure
Hi,
I really envoy the latest Calibre version... I have a source LibreOffice odt document with this structure (I cannot change it, it's an European law): Code:
Chapter 1
Section 1
Article 1
Article 2
Section 2
Article 3
Article 4
Chapter 2
Article 5
Article 6
As you see, sometimes there is no Section (h2) between Chapter (h1) and Article (h3). Using the TOC from LibreOffice generate an ugly TOC, and using standard "//*[name()='h2']" for Level 2 misses Articles; using "//*[name()='h2' or name()='h3']" puts all Articles in Level 2... Please, how can I create automatically a nice TOC with this structure? Last edited by Cilex; 10-01-2016 at 07:13 PM. Reason: (cleaned last line) |
|
|
|
|
|
#2 |
|
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,300
Karma: 62000000
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
the indented TOC will create just fine with a missing level (ncx, html FROM ncx)
It may look a little ragged since H3 without H2 just moves into that position H1 H2 H1H3 H3
|
|
|
|
| Advert | |
|
|
|
|
#3 |
|
Junior Member
![]() Posts: 2
Karma: 10
Join Date: Mar 2015
Device: iphone
|
I'm not sure I understand your answer... If I do leave Auto Generation "On" from the original file, it just creates garbage TOC.
And if I do define TOC levels 1, 2, 3, Level 3 is not generated - because Level 2 was not, I guess - so Chapter 2 has no sub-titles. |
|
|
|
|
|
#4 |
|
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,300
Karma: 62000000
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Try using the TOC tool (standalone or p/o the editor) instead of relying on the basics of Conversion - Detection.
It also offers more choices (ways) than included in the Conversion |
|
|
|
![]() |
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Create tags while importing from source folder structure | eamonned | Library Management | 5 | 01-28-2019 10:37 AM |
| Ho do I create a TOC for ePub which does convert to an active TOC in Kindle Previewer | K-Thom | Calibre | 1 | 09-24-2013 07:32 PM |
| [Old Thread] Create just one TOC | medwatt | Conversion | 27 | 12-18-2012 06:55 PM |
| Create Newspaper TOC | plantoschka | Kindle Formats | 2 | 09-09-2010 03:03 PM |
| How to create a TOC from scratch? | greenapple | Sigil | 5 | 06-01-2010 03:20 AM |