03-11-2011, 09:29 AM | #1 |
Overenthusiastic Noob
Posts: 69
Karma: 896
Join Date: Feb 2011
Location: France
Device: Kindle 3
|
Different text in TOC & actual chapter title
Hello everyone!
Very simply, what I'm trying to do, converting from html to mobi is: When the actual chapter title in the book is "1", I want the corresponding TOC line to say "Chapter 1". Can I do this with the Calibre XPath TOC generator thingy? I've tried making a TOC by hand (anchor + links) but when I upload the book to my Kindle, the "GoTo" function doesn't detect the TOC even when using the <a name="TOC"/> tag. |
03-11-2011, 09:55 AM | #2 |
Well trained by Cats
Posts: 29,800
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
I use Sigil to modify my epub files (and I don't own a Kindle )
Code:
<h3 title="Chapter 1">1</h3>
|
03-11-2011, 10:06 AM | #3 |
Overenthusiastic Noob
Posts: 69
Karma: 896
Join Date: Feb 2011
Location: France
Device: Kindle 3
|
I found the solution to part #2 of my problem (making the Kindle recognize my "hand-made" TOC as such) by chance while browsing a completely unrelated thread (seriously, does this only happen to me?).
But the reason I was asking whether Calibre has a sort of "add 'Chapter' to all entries" function hidden somewhere was precisely to avoid the manual tagging of all chapters - whether by adding anchors or titles. But I'll try Sigil anyway. Even though I'm not gonna make epubs, it's bound to come in handy. |
03-11-2011, 04:27 PM | #4 | |
Fanatic
Posts: 541
Karma: 1152752
Join Date: Aug 2010
Location: Evansville, IN, USA
Device: Samsung Galaxy Tab 4 Nook & Samsung Galaxy Tab S 10.5
|
Quote:
As far as how to have different text show up in the toc, that's really easy. Most ebooks use the "h" tags to setup toc entries. As part of the tag, add title="whatever text you want to show up" and that text will be displayed rather than the actual text you see on the screen. It works the same if you want to use an image as the chapter header but have text show up in the toc. If you're toc is a simple, one layer/linear toc, just use the Sigil toc editor and "h" tags and Calibre will automatically create the toc for you upon conversion. If your toc has multiple or nested levels, you should probably create a proper toc file in the ebook but, again, that's pretty easy after you've experimented and looked at some other ebooks to see how it's done. I hope this helps a little. Let me know if you need any more assistance or advice. I'll be glad to pass on what I've learned if I can. - Byron |
|
03-11-2011, 04:54 PM | #5 | |
Groupie
Posts: 180
Karma: 558490
Join Date: Jan 2011
Device: Kindle 5, Amazon Fire 5th Gen, Moto Z Play Droid
|
Quote:
|
|
03-12-2011, 01:00 PM | #6 |
Overenthusiastic Noob
Posts: 69
Karma: 896
Join Date: Feb 2011
Location: France
Device: Kindle 3
|
Well I took a quick look at Sigil and it's definitely not going to work for me, if only because it doesn't match my usual workflow at all. I've taken the habit of using Notepad++ to edit the file (<3 RegEx) together with a somewhat generic css I reuse in every file, and sometimes Kompozer to finetune the css when I wanna tweak indents or margins a bit (although it tends to lag like a b***h on the bigger files).
So I don't think that Sigil would fit into this :P Which was okay because I realized that making a TOC "by hand" (with anchors and links) is very satisfying... except I'm now facing a new problem, which is that Calibre duplicates the TOCs, even when ticking "don't add detected chapters" -.- |
03-12-2011, 01:47 PM | #7 | |
Fanatic
Posts: 541
Karma: 1152752
Join Date: Aug 2010
Location: Evansville, IN, USA
Device: Samsung Galaxy Tab 4 Nook & Samsung Galaxy Tab S 10.5
|
Quote:
You wouldn't have near the problems you're describing. I really have trouble understanding why you'd want to use Notepad++ to edit your file rather than a WYSIWYG editor designed for ebooks. To me it seems sort of like someone still developing web pages by hard-coding in a text editor instead of using a real web development tool. That's just me though and it's your work flow. You do what you want. I wish you the best of luck however you decide to proceed. - Byron |
|
03-12-2011, 02:29 PM | #8 |
Overenthusiastic Noob
Posts: 69
Karma: 896
Join Date: Feb 2011
Location: France
Device: Kindle 3
|
I gotta say that this workflow is both young and sort of an improvisation. I only got a Kindle a few weeks ago and I gotta say that when you know nothing about coding and ebooks, it's all very overwhelming - I took cues from whichever website or forum thread I happened to land on, leading to quite a circumvoluted method made from bits and pieces.
My forum peregrinations only lead me to discover Sigil a couple of days ago, so I still have much learning to do I however quickly realized that I'm somewhat of a control freak when it comes to my ebooks, and I can't stand finding a stray tag that I didn't put myself, or being unable to check exactly what it does in the css or to tweak the quotes' bottom margin whenever I feel it's 1pt too wide. I also might have gone overboard with my "formatting options". I have set classes for every type of situation: books with Parts and Chapters, Parts that have specific quotes, Chapters that have introductions, Subchapters that need a page-break-before, etc. - all of those having different text sizes, indents or margins - depending on the book, of course. Also I might need to mention that most of my ebook-making has to do with free content: public domain books, fanfic, essays, etc. that are published on websites and that often need a lot of precise formatting to be readable. But you guys really made me wanna look at the whole process from a fresh perspective so I'll give Sigil another try, and try to let go of the formatting OCDs. |
03-12-2011, 04:04 PM | #9 |
Fanatic
Posts: 541
Karma: 1152752
Join Date: Aug 2010
Location: Evansville, IN, USA
Device: Samsung Galaxy Tab 4 Nook & Samsung Galaxy Tab S 10.5
|
Don't feel too badly. I'm the same way. I think I just go about things a little differently and feel my processes are probably a little more matured than yours (of course I'd feel that way, they're my processes, right? ) I've definitely come a long way in six months of editing/creating/converting. I've learned a lot, forgotten a lot, picked up a lot of bad habits, dropped them and learned more. My processes have changed considerably in that time and my results show for it. Never let yourself get so confined by a process that you can't or won't use a better method, or at least try something new when it comes along.
Trust me though, I'm every bit as anal retentive when it comes to my ebook formatting, and there's nothing wrong with that. Just find a method that works for you but, at the same time, is as easy on you as it can be. Also, if you haven't downloaded it yet, another useful tool is the Amazon Kindle Previewer. It's basically a Kindle emulator and will show you what your mobi file will look like on your Kindle. While Calibre will let you view a mobi file, it won't give you any idea what it will really look like on a real-live Kindle. - Byron |
03-12-2011, 05:15 PM | #10 |
Overenthusiastic Noob
Posts: 69
Karma: 896
Join Date: Feb 2011
Location: France
Device: Kindle 3
|
|
03-12-2011, 10:32 PM | #11 | |
US Navy, Retired
Posts: 9,864
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Nexus 7
|
Quote:
Sigil might not work for you but it is more flexible and powerful than a first glance might reveal. |
|
03-13-2011, 06:09 AM | #12 | |
Enquiring Mind
Posts: 562
Karma: 42350
Join Date: Aug 2010
Location: London, UK
Device: Kindle 3 (WiFi)
|
Quote:
Also, just a clarification - the "TOC" that others refer to Sigil creating is not an inline TOC as required in a MOBI file. What Sigil creates is a navigation control XML file (an NCX file) which most/all EPUB readers use to generate a TOC to present to the user. The Kindle device and apps use the NCX file (when one is incorporated into a MOBI file) to provide previous/next chapter navigation (on the Kindle, using the 5-way control button), and to show each navigation point as a small dot or tick mark on the progress bar. In most MOBI readers, and certainly true for the Kindle and Kindle apps, the only kind of TOC that will be presented to the user viewing a MOBI file is an inline TOC, coded as part of the HTML content of the book. That's the TOC referred to in Calibre's conversion dialog when MOBI is selected as the output format. |
|
03-13-2011, 06:47 AM | #13 | |
Fanatic
Posts: 541
Karma: 1152752
Join Date: Aug 2010
Location: Evansville, IN, USA
Device: Samsung Galaxy Tab 4 Nook & Samsung Galaxy Tab S 10.5
|
Quote:
- Byron |
|
03-13-2011, 07:09 AM | #14 | |
Enquiring Mind
Posts: 562
Karma: 42350
Join Date: Aug 2010
Location: London, UK
Device: Kindle 3 (WiFi)
|
Quote:
There's also the issue of Calibre placing that inline TOC at the end of the book, which isn't exactly where users would expect to find it. Of course, that's only an issue if you plan on distributing the ebook to others. If it's purely for your own consumption, it becomes simply a matter of personal preference. |
|
03-13-2011, 08:04 AM | #15 | |
Fanatic
Posts: 541
Karma: 1152752
Join Date: Aug 2010
Location: Evansville, IN, USA
Device: Samsung Galaxy Tab 4 Nook & Samsung Galaxy Tab S 10.5
|
Quote:
I like having a TOC in my ebooks, in-line for mobis for my Kindle, but I don't want to have to scroll through it at the beginning of all my books, so I always put mine at the end anyway. Like you said, where it gets put is a personal choice. You can put it whereever you want if you create it yourself but if you let Calibre create it for you, it's definitely going to be in the back. That's great for me. Maybe not so much for someone else. - Byron |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre settings for using 'chapter' in TOC | TargonD | Calibre | 13 | 11-03-2010 08:57 PM |
Les Miserables - TOC / Chapter Flags? | gshipley | Amazon Kindle | 1 | 09-28-2009 10:07 PM |
ADE and long chapter names in ToC | frabjous | Reading and Management | 3 | 08-14-2009 11:16 AM |
Chapter or TOC Creation help needed | gandor62 | Calibre | 4 | 04-15-2009 02:18 PM |
html2epub TOC and chapter detection help | ilovejedd | Calibre | 6 | 02-22-2009 05:58 PM |