Thread: Editing toc
View Single Post
Old 10-12-2012, 08:40 AM   #4
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 27,553
Karma: 193191846
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by exaltedwombat View Post
Could I have done this more easily by direct editing toc.ncx? I can't see from examining it how the hirearchy is set.
You could have done it by directly editing the toc.ncx. "More easily" is extremely relative.

navPoints are nestable ... as per this example:
Code:
<navMap>
  <navPoint id="np_1" playOrder="1">
    <navLabel>
      <text>Blah</text>
    </navLabel>
    <content src="Text/part0001.xhtml"/>
    <navPoint id="np_2" playOrder="2">
      <navLabel>
        <text>1</text>
      </navLabel>
      <content src="Text/part0002.xhtml"/>
    </navPoint>
  </navPoint>
<navMap>
"Flattening" that same toc.ncx would necessitate un-nesting the navPoints (putting them on the same level):
Code:
<navMap>
  <navPoint id="np_1" playOrder="1">
    <navLabel>
       <text>Blah</text>
    </navLabel>
    <content src="Text/part0001.xhtml"/>
  </navPoint>
  <navPoint id="np_2" playOrder="2">
    <navLabel>
      <text>1</text>
    </navLabel>
    <content src="Text/part0002.xhtml"/>
  </navPoint>
<navMap>
Hope that helps!

Last edited by DiapDealer; 10-12-2012 at 08:50 AM.
DiapDealer is offline   Reply With Quote