|
|
Thread Tools | Search this Thread |
09-04-2024, 03:34 PM | #16 |
Member
Posts: 10
Karma: 10
Join Date: Sep 2024
Device: none
|
Thank you for the suggestion DNSB. However, I don't think that will work.
When I set --level1-toc to //*[(name()='h1' or name()='h3')] it gathers all <h1> tags and all <h3> tags and makes them ToC items at level1. I'm worried at this point the command line ebook-convert tool just doesn't make ToCs at the full depth that I need. I don't see a way to make <h4> and <h5> tags turn into level4 and level5 ToC elements. It seems like the GUI is the only way to make ToCs up to 5 or 6 levels deep. Am I missing anything? Or am I correct that ebook-convert can only make ToCs with three levels of ToC elements? |
09-04-2024, 03:49 PM | #17 |
Member
Posts: 10
Karma: 10
Join Date: Sep 2024
Device: none
|
If ebook-convert doesn't make ToC with depth >3, is there any other automated way to do that? Like a script in Calibre's code base I could use?
It would be really helpful to automate this rather than use the UI. Thanks for any suggestions. |
09-04-2024, 10:25 PM | #18 |
creator of calibre
Posts: 44,507
Karma: 24495778
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Yeah conversion, whether from the gui or the command line can generate at most depth 3 tocs You will find that some ebook readers have issues with even that depth. If you want deeper tocs you need to use the toc edit tool after conversion.
|
09-05-2024, 09:55 AM | #19 |
Member
Posts: 10
Karma: 10
Join Date: Sep 2024
Device: none
|
I didn't know some e-readers handle deeper ToCs poorly. Thanks. I wondered why the CLI would be limited to three ToC levels. I'll stick with that.
Thanks to everyone for your help. Also, FYI, the reason I posted several times in a row yesterday was that some posts appeared instantly and some appeared only after a delay, so I wasn't sure they had actually submitted properly. Didn't mean to spam the thread. |
09-05-2024, 10:05 AM | #20 | |
Grand Sorcerer
Posts: 12,725
Karma: 75000000
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
|
Quote:
Sent from my Pixel 7a using Tapatalk |
|
09-05-2024, 10:23 AM | #21 |
Resident Curmudgeon
Posts: 76,332
Karma: 136006010
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
|
09-05-2024, 11:24 AM | #22 |
Well trained by Cats
Posts: 30,441
Karma: 58055868
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Book Production?
Arnold Bailey used a very early Calibre for Webscriptions (Baen's entry into e-books). There were Calibre footprints all over the EPUB. Ask @Hitch (or other book wranglers that haunt MR) if they use the command line or GUI . But, with the power of recent (I am calling a Decade ago recent?) Calibre and plugins. Why! is a good question. Remoting in over a 300baud line, command line is really the way to go For just TOC work, you can add a TOC icon onto the main GUI. (I only work on EPUB2 for personal use, so I dont know if this works for a NAV. But I suspect, neither does the CLI. |
09-05-2024, 01:37 PM | #23 |
Zealot
Posts: 106
Karma: 1133068
Join Date: Sep 2007
Device: ipaq
|
|
09-05-2024, 04:11 PM | #24 |
Bibliophagist
Posts: 40,400
Karma: 156982136
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
|
For me, one off tasks are done from the GUI. If there is a task that is going to be done multiple times and can be automated using the CLI, I see no reason for me to waste my time doing repetitive tasks when the computer can do them for me.
|
Tags |
toc, toc creation |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
create a useable TOC when book uses images for chapter headings | stumped | Sigil | 23 | 06-09-2019 04:12 PM |
How to insert automatically valid id's in ToC headings? | chaot | Editor | 18 | 02-01-2017 07:55 AM |
Generated TOC at beginning of PDF via command line | alexandreaquiles | Conversion | 1 | 10-12-2014 04:24 AM |
HTML to Epub conversion isn't generating TOC through command line | marcosalles | Conversion | 1 | 02-20-2014 11:09 PM |
Calibre Command Line Interface TOC | bcolflesh | Calibre | 3 | 02-04-2010 05:09 PM |