![]() |
#1 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Dec 2010
Device: Kindle
|
Kindle Table of Contents
Hello,
I've searched through the forum and have not been able to find a post that precisely addresses my question. I'm a beginner with the Calibre software but so far I have been able to scan several chapters of a book, port them into Word 2007, create a table of contents, save the file as an html document, successfully use Calibre to create a mobi file, and download the file to my Kindle 3. My Kindle recognizes everything, including the table of contents. The links in the TOC are active and work as desired. I even see the little tic marks on the progress line on the bottom of the pages where you can tab to the start of each chapter using the 5-way button. My question is a simple one. I have all this working correctly but the thing I cannot get to work is when I press the Kindle 'Menu' key, and then click 'Go to...', The 'Table of Contents' selection is grayed out. It would seem this would be active so I could easily tab to the TOC. Can somone give me an idea as to how to surrmount this final obstacle? Other than this small thing, everything is working perfectly. many thanks, Brian P |
![]() |
![]() |
![]() |
#2 |
Connoisseur
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 73
Karma: 11638
Join Date: Aug 2010
Location: Spain
Device: iPad, Kindle Paperwhite, Kobo Libra 2
|
I believe you are generating an inline TOC. The true Table of Contents is metadata-based (not a page of the book) and it's defined in the toc.ncx file.
Create a Basic toc.ncx file Search also in these forums, there have been discussions, like for example: https://www.mobileread.com/forums/sho...56&postcount=6 Last edited by Coleccionista; 12-16-2010 at 02:11 PM. Reason: Add link to MR post |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Addict
![]() ![]() ![]() ![]() ![]() Posts: 219
Karma: 404
Join Date: Nov 2010
Device: Kindle 3G, Samsung SIII
|
I guess that you need to specifically tag your TOC items (for instance adding toc='toc_level1' atribute to every level 1 entry in the TOC) and let Calibre know about your tags in the TOC section (fill in the XPath for level 1 TOC etc) when converting to MOBI.
In addition, you may also want to check the "Do not add TOC to book" option in the MOBI output section as from your description you already have put it to the desired place in the book yourself. Last edited by janvanmaar; 12-16-2010 at 02:14 PM. |
![]() |
![]() |
![]() |
#4 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 6,249
Karma: 16539642
Join Date: Sep 2009
Location: UK
Device: ClaraHD, Forma, Libra2, Clara2E, LibraCol, PBTouchHD3
|
How did you mark Chapter headings in your Word doc?
Suppose you had styled them with the Word built-in style 'Heading 2', then when you Saved-As Webpage-filtered the Chapters would be tagged with <h2>...</h2> tags. Then after importing the html into calibre you would run a conversion ZIP to MOBI, with conversion settings: Convert - StructureDetection - Detect Chapters at: //h:h2 Convert - TableofContents - Level 1: //h:h2 This would create a single-level metadata TOC (in file toc.ncx) in your MOBI. Nothing at all to do with the inline one you already have. |
![]() |
![]() |
![]() |
#5 |
Enquiring Mind
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 562
Karma: 42350
Join Date: Aug 2010
Location: London, UK
Device: Kindle 3 (WiFi)
|
The Kindle doesn't present the NCX table of contents directly to the user - it's only used internally by the device software to place to "navpoint" tick marks on the progress bar, and allow single-key jumping to the next or previous navpoint using the 5-way controller. The OP reports that the TOC he created works fine - that's an inline TOC, part of the book itself. He also reports that the tick marks are present in the progress bar and he can navigate to next/previous chapter using the 5-way control, so the NCX file is present and correct. What he needs is a way to tell the Kindle where in the book to find the inline TOC.
Brian - what's needed is to add an HTML bookmark to your HTML file to mark the start of the TOC (e.g. <a id="toc" />), and then a way of creating a "guide" item in the OPF file that is built into the MOBI file, pointing to that bookmark as the start of the inline TOC. That's what the Kindle needs, to be able to find the TOC. Someone else who knows Calibre better will correct me if I'm wrong, but I don't think there's any way of doing that directly in Calibre while converting HTML to MOBI. What I'd suggest is using Mobipocket Creator first to create an initial MOBI file, during which process you can add a "toc" guide item to point to the bookmark you created in the HTML file (using the above example bookmark, you would set the "toc" guide item to point to "your_book_filename.html#toc"). Once you've done that, you can load the resulting MOBI file into Calibre, then convert MOBI > MOBI, which will add the "hidden" NCX table of contents which provides the chapter navigation points for the 5-way controller to use. Edit to add: If you add the "toc" bookmark at the appropriate point in the Word doc, that will translate into the appropriate HTML bookmark of the same name when you save that doc to HTML. End of edit I hope that made some sort of sense! ![]() Last edited by DMSmillie; 12-16-2010 at 03:37 PM. |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Dec 2010
Device: Kindle
|
Many thanks for the several suggestions. I will be taking next week off and I will attempt to implement some of the ideas. Unfortunately, I am a neophyte when it comes to HTML code so it will take some time on my part as I ascend the learning curve.
|
![]() |
![]() |
![]() |
#7 |
Addict
![]() ![]() ![]() ![]() ![]() Posts: 219
Karma: 404
Join Date: Nov 2010
Device: Kindle 3G, Samsung SIII
|
Perhaps a short summary of the suggestions with some notes would help you:
1. jackie_w's suggestion is the simplest - it does not require anything else from you than telling Calibre what did you use for chapter definitions in your editor (header2 in his example). However, the TOC created in this way only includes the chapter names exactly as they are in the book and thus can, generally, be different from the TOC you created before. For example, it will always create an entry "Chapter name" as in stands in the book while you may have used eg "Chapter x: Chapter Name" format. If this is ok, then you do not need to look any furher and simply use this suggestion. 2. my suggestion tries to enable your custom TOC entries simply by copying every entry to the required place in the book and giving it a special tag which you then specify to Calibre in TOC detection section, similarly as you would do with h2 tags in jackie's case. I should have mentioned that you almost certainly want to wrap the entries in <div style="visibility:hidden"> tags, otherwise they would appear in the book itself. 3. clearly, my suggestion is suboptimal since if you already have your TOC in the HTML, there should be a way to simply use that instead of reproducing it again. However, I did not know how to do that with Calibre and DMSmillie also does not know but suggests using combined Mobipocket Creator - Calibre scheme for this purpose. Hope this helps a bit ![]() |
![]() |
![]() |
![]() |
#8 |
Addict
![]() ![]() ![]() ![]() ![]() Posts: 219
Karma: 404
Join Date: Nov 2010
Device: Kindle 3G, Samsung SIII
|
EDIT: from some reason duplication of my previous post was created so I deleted it...
Last edited by janvanmaar; 12-16-2010 at 04:47 PM. |
![]() |
![]() |
![]() |
#9 |
Enquiring Mind
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 562
Karma: 42350
Join Date: Aug 2010
Location: London, UK
Device: Kindle 3 (WiFi)
|
The thing is, janvanmaar - Peter already has a working, inline TOC (the only kind that the Kindle makes available to the user), and in creating the MOBI file with Calibre, the ncx TOC is being correctly created, since he's able to navigate using the Kindle's 5-way control. What isn't working is the Kindle's "Go To..." menu entry which, if it was working, would take the reader to the inline TOC. As far as I know, the only way to enable that to work is via a type="toc" guide item pointing to the start of the inline TOC in the HTML file.
If Peter was hand-crafting the source files to compile into the MOBI file, it would be relatively straightforward - add the HTML bookmark at the appropriate point in the HTML file, and add the appropriate item to the guide section of the OPF file to point to the location of the inline TOC in the HTML file. Then he could use Kindlegen, for example, to combine the OPF file, NCX file, HTML file and (if included) cover image into a MOBI file. The issue here is how to get that guide item into the MOBI file so that the Kindle knows where to find the inline TOC. |
![]() |
![]() |
![]() |
#10 |
Addict
![]() ![]() ![]() ![]() ![]() Posts: 219
Karma: 404
Join Date: Nov 2010
Device: Kindle 3G, Samsung SIII
|
DMSmillie: I agree. Calibre adds that guide automatically when it is creating the TOC from the XPath definitions in the TOC section (ok, I did not check the source but I always get *both* 5-way key navigation and TOC in GoTo when creating TOC in this way). But of course, there may (should) be a better solution.
Last edited by janvanmaar; 12-16-2010 at 06:19 PM. |
![]() |
![]() |
![]() |
#11 |
Enquiring Mind
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 562
Karma: 42350
Join Date: Aug 2010
Location: London, UK
Device: Kindle 3 (WiFi)
|
Aha! That was the bit of info I was missing (also got it in parallel with your reply here, from KovidGoyal in response to the question I asked in a separate post). Thanks janvanmaar!
Looks like, when using Calibre to create the MOBI file, that's the only way of getting that marker to the location of the inline TOC. Brian - if you're happy to let Calibre create another TOC at the end of the book based on your section/chapter headings, that one will be marked in such a way that the Kindle will be able to identify it as the TOC, and the Kindle's "Go To... Table of Contents" menu link will point to it. Last edited by DMSmillie; 12-16-2010 at 06:44 PM. Reason: typo |
![]() |
![]() |
![]() |
#12 | |
Addict
![]() ![]() ![]() ![]() ![]() Posts: 219
Karma: 404
Join Date: Nov 2010
Device: Kindle 3G, Samsung SIII
|
Quote:
Plus, the "Do not add TOC to book" option in the MOBI output section can be used to supress adding another TOC to the end of the book which I guess Brian may want in his case. |
|
![]() |
![]() |
![]() |
#13 | |
Enquiring Mind
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 562
Karma: 42350
Join Date: Aug 2010
Location: London, UK
Device: Kindle 3 (WiFi)
|
Quote:
And... if you tick "Do not add TOC to book", then you won't get the addition of the guide item in the MOBI file which tells the Kindle where to find an inline TOC. See https://www.mobileread.com/forums/sho...d.php?t=111600 |
|
![]() |
![]() |
![]() |
#14 | ||
Addict
![]() ![]() ![]() ![]() ![]() Posts: 219
Karma: 404
Join Date: Nov 2010
Device: Kindle 3G, Samsung SIII
|
Quote:
Quote:
|
||
![]() |
![]() |
![]() |
#15 |
Junior Member
![]() Posts: 3
Karma: 10
Join Date: Dec 2010
Device: Kindle
|
Wow, you folks are certainly generous with your suggestions. I hope I can do them credit in figuring this out.
many thanks again, Brian |
![]() |
![]() |
![]() |
Tags |
kindle, toc |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Kindle DX and PDF Table of Contents | Gideon | Amazon Kindle | 12 | 03-19-2012 06:14 PM |
Kindle: how create table of contents at the bottom line? | ganymede | Calibre | 1 | 11-09-2010 01:43 AM |
Help with my Table of Contents | Skylinefranc | Calibre | 0 | 03-19-2010 12:55 AM |
How to: table of contents | wizzofoz | Sigil | 1 | 10-08-2009 08:22 AM |
Creator Table of Contents | Nate the great | Kindle Formats | 5 | 07-10-2008 05:55 AM |