Mobileread
Marvin not reading epub table of contents as created
#1  hikarisama010 10-23-2020, 11:02 PM
Hey all,

I'm consolidating a six book series into a single omnibus version, just to make my library a bit neater. But I'm encountering a issue where Marin seems to be unable to read the new ToC as made for the omnibus, refusing to display the full ToC even where other readers have no issue.

I'm using:
iPhone XR iOS 13.7
Marvin 3.1.2 build 34
Calibre 5.3 with EpubMerge 2.11.0

I merged books 1-6 together using EpubMerge, and verified that the ToC looks as its suppose to on calibre's native reader, on SumatraPDF, and with the reader on the Readder Documents app on my phone.

The ToC shows up as I had made it on all of those other readers, except for Marvin. Marvin decided that its just going to show the first book, or the first three books, depending on criteria that I'm evidently not privy to.

I did a couple of test then, using EpubMerge's settings to keep the ToC from the individual books at this point with no editing of the ToC or epub sections.
- It will show all chapters for Books 1, 2 & 3 omnibus
- It will only show book 1 chapters for Books 1, 2, 3 & 4 omnibus
- It will show all chapters for Books 4, 5 & 6 omnibus
- It will show all chapters for Books 3, 4, 5 & 6 omnibus
- It will only show book 2 chapters for Books 2, 3, 4, 5, & 6 omnibus

I'm at a loss with this. It's doesn't seem to be a book limit, as I have another omnibus that is eight books long that has a complete ToC on Marvin.

Is there any documentation on how Marvin reads ToC data from epubs?
It sure doesn't seem like its reading the changes I initially made, or the auto-generated ones from EpubMerge half the time. Can anyone shine some light on this? Do I need to go in and edit the section names or something?
Reply 

#2  hikarisama010 10-24-2020, 01:44 PM
Just a small update, I tried editing the section names, but that didn't fix anything.

Tried merging the 1-3 and 4-6 omnibuses (that have correct ToCs in Marvin) into a 1-6 omnibus, but the same issue occurs where Marvin only displays the chapters of book 1. If I reconvert the 1-6 omnibus using default Calibre settings, Marvin then seems to pick up on the six top level ToC entries for each book, but the chapters of each are completely scrambled underneath them randomly:

Book 1
- Prologue
Book 2
- Chapter 1
Book 3
- Chapter 2
- Chapter 3
- Prologue
- Chapter 4
- Chapter 1
- Chapter 5
- Chapter 2
Book 4
- Chapter 9
etc,etc.

I have another 8 and 17 books omnibuses with ToCs that Marvin reads just fine, but another 12 book omnibus where it starts to mess up around book 7. I've been using the exact same process for each, all of these omnibuses were made after I updated to iOS 13.7 a month ago, but I can't figure out why some ToCs are fine and others are not.
Reply 

#3  Turtle91 10-27-2020, 08:40 PM
It must be in your code somewhere. Unfortunately, I can't help with that unless I can see the code...

I tend to split omnibuses into their individual books...no need to slow down the renderer by transferring huge files. But the concept, and coding, is the same for books that have parts and chapters.

I use the <h1>-<h6> tags to create a proper hierarchy. Then Sigil, and I'm pretty sure Calibre does it too, will auto create the ToC and it works perfectly in Marvin.

You can also look at your ncx file to make sure it makes sense...or use Sigil's ToC editor which will create a proper ncx.

Also...if nothing else works...try selecting Publisher's mode in Marvin...select the Aa and scroll down???

Cheers,
Reply 

#4  hikarisama010 10-27-2020, 09:13 PM
I'm very very new to all this, so please forgive my ignorance.

I can definitely imagine that I messed up a setting somewhere that ruined the ToC, but if that were the case, shouldn't the ToC be ruined no matter which reader I used?

The fact that the ToC displays properly and works as intended on every other reader I've used, just not Marvin, is puzzling me to no end.
Reply 

#5  JSWolf 10-27-2020, 09:15 PM
Quote hikarisama010
I'm very very new to all this, so please forgive my ignorance.

I can definitely imagine that I messed up a setting somewhere that ruined the ToC, but if that were the case, shouldn't the ToC be ruined no matter which reader I used?

The fact that the ToC displays properly and works as intended on every other reader I've used, just not Marvin, is puzzling me to no end.
Maybe the other programs are more forgiving of errors and Marvin is not.
Reply 

#6  hikarisama010 10-30-2020, 02:03 PM
Thanks for the pointers. Importing the omnibus into Sigil shows the ToC that I made, but it appears most of the chapters don't have proper h1-h6 tags, as the Sigil auto-generated ToC is very very sparse. I'm hoping that this is the issue, that Marvin reads ToC from heading tags. So I'll try and clean that up and see if that helps at all.
Reply 

#7  Turtle91 11-01-2020, 11:12 AM
Sigil's ToC generator uses the <h> tags to create the ToC.

There are some shady-unwashed-peasant type publishers that use <p> or <div> tags for headings - even though the heading tag is designed for...headings... - I say they should all get 50 lashes with a wet noodle!!

You can use CSS to style - make them look like - anything you want. The same CSS will make p/div/h tags look the same, so there really is no reason to NOT use the semantically correct tag...in fact, using the correct tag allows reading devices and editing software to work properly... as you found out with the ToC generators.

eg.
Code
CSS:
h3 {font-size:1.2em; text-align:center; font-weight:bold}
h3 span {display:block; font-size:1.1em; font-weight:normal; font-variant:small-caps; margin:1em auto}
HTML:
<h3>Chapter 4 <span>The Way it Should Be</span></h3>
is much better than
Code
CSS:
p.I_want_this_to_look_like_a_header
{font-size:1.2em; text-align:center; font-weight:bold}
p.This_is_the_chapter_sub-title
{font-size:1.1em; text-align:center; font-weight:normal; font-variant:small-caps; margin:1em 0}
HTML:
<p class="I_want_this_to_look_like_a_header">Chapter 4</p>
<p class="This_is_the_chapter_sub-title">The Way it Should not Be</p>
Reply 

Today's Posts | Search this Thread | Login | Register