08-07-2009, 01:20 AM | #1 |
Enthusiast
Posts: 27
Karma: 32
Join Date: Aug 2009
Device: Kindle 2
|
TOC created with EPUB but not LRF?
OK, this is driving me bananas. I've spent the past two days off and on trying to clean up some RTF books into html and then convert them to LRF for viewing on my PRS-505. I've saved the RTF out to html using the microsoft word "filtered html" option and then run it through HTML tidy to clean things up. I've then created an XPath expression to detect my chapters, it looks like this:
Code:
//*[((@class = 'c1') and re:test(., 'chapter|book|section|part\s+', 'i')) or @class = 'chapter'] |
08-07-2009, 02:08 AM | #2 |
Enthusiast
Posts: 27
Karma: 32
Join Date: Aug 2009
Device: Kindle 2
|
OK, shedding some more light on the subject... my chapter headings are inside <span></span> tags... when I manually remove them and put them in <p></p> tags, the TOC is created correctly... I really don't want to go in and manually reformat 7 books worth of chapter headings though...
|
Advert | |
|
08-07-2009, 01:10 PM | #3 |
creator of calibre
Posts: 44,551
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
This is with what version of calibre?
|
08-07-2009, 01:47 PM | #4 |
Enthusiast
Posts: 27
Karma: 32
Join Date: Aug 2009
Device: Kindle 2
|
Hi kovidgoyal, thanks for responding! (You the man by the way...) This is with the latest version 0.6.5. I've attached a trimmed-down version of what I'm trying to get to work, perhaps it'll help.
|
08-07-2009, 04:09 PM | #5 | |
hopeless n00b
Posts: 5,110
Karma: 19597086
Join Date: Jan 2009
Location: in the middle of nowhere
Device: PW4, PW3, Libra H2O, iPad 10.5, iPad 11, iPad 12.9
|
Quote:
|
|
Advert | |
|
08-07-2009, 04:26 PM | #6 | |
Enthusiast
Posts: 27
Karma: 32
Join Date: Aug 2009
Device: Kindle 2
|
Quote:
|
|
08-07-2009, 08:05 PM | #7 |
creator of calibre
Posts: 44,551
Karma: 24495948
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
That's because the HTML to LRF conversion doesn't support anchors on inline elements like <span>
|
08-07-2009, 08:24 PM | #8 |
Enthusiast
Posts: 27
Karma: 32
Join Date: Aug 2009
Device: Kindle 2
|
So I need to get rid of all my <span> elements? That'll be fun... here I was hoping to keep the formatting of this book as close as possible to the original...
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
TOC not showing in eBook created by InDesign | gabrieleale | Sony Reader | 0 | 07-30-2010 05:02 PM |
505 TOC from PDF to EPUB/LRF | wayamauro | Sony Reader | 18 | 09-27-2009 05:21 AM |
TOC not created converting from FB2 | regul8or | Calibre | 1 | 08-03-2009 01:26 PM |
Making a TOC for LRFs? Issues with Calibre + LRF TOC editor not working | Magitek | LRF | 0 | 05-06-2009 02:25 PM |
TOC in LRF | sAGV | Sony Reader | 14 | 12-18-2007 11:50 AM |