Quote:
Originally Posted by John F
On the book menu, there is an menu entry "Table of Contents". When that is selected, a window is shown that says "Table of Contents" at the top. This is where I would like the page numbers. I assume this is what you are referring to as "TOC displayed by parsing the toc.ncx file"
|
Part of the epub2 standard is a toc file called toc.ncx. This file uses navmap and navpoint tags to define entries in the table of contents. This is the file used by table of contents popup on Kobo's ereaders.
Code:
<docTitle>
<text>The Honor of the Queen</text>
</docTitle>
<navMap>
<navPoint id="6302f89b-4dd6-4683-afc1-501942c14eab" playOrder="1">
<navLabel>
<text>CHAPTER ONE</text>
</navLabel>
<content src="Text/0743435729__p__split_001.htm"/>
</navPoint>
<navPoint id="f21a31ad-6d43-4003-9ca7-f2958fccef50" playOrder="2">
<navLabel>
<text>CHAPTER TWO</text>
</navLabel>
<content src="Text/0743435729__p__split_002.htm"/>
</navPoint>
<navPoint id="8fa502c6-449e-4c47-a4b0-75692d6dced7" playOrder="3">
<navLabel>
<text>CHAPTER THREE</text>
</navLabel>
<content src="Text/0743435729__p__split_003.htm"/>
</navPoint>
<navPoint id="99942f95-e4cc-4015-acfe-889fbf2bd2bf" playOrder="4">
<navLabel>
<text>CHAPTER FOUR</text>
</navLabel>
<content src="Text/0743435729__p__split_004.htm"/>
</navPoint>
<navPoint id="24f63042-669c-4745-a90a-b5815727f66f" playOrder="5">
<navLabel>
<text>CHAPTER FIVE</text>
</navLabel>
<content src="Text/0743435729__p__split_005.htm"/>
</navPoint>
To make things more fun, Epub3 deprecates the toc.ncx file and goes with a xhtml file using nav tags. The toc nav tag with a meaning similar to the old navmap tag is the only one I've seen used so far but there is a page-list nav element which can contain page numbers derived from a printed book which is again somewhat similar to the pagelist tag but with some effort to make it useful for more than causing confusion.
Regards,
David