View Single Post
Old 06-03-2019, 04:22 AM   #1
stumped
Wizard
stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.stumped ought to be getting tired of karma fortunes by now.
 
Posts: 3,305
Karma: 10259306
Join Date: May 2016
Device: kobo forma, Kobo Libra, Huawei media Tab, fire HD10, PW3 HDX8.9,
create a useable TOC when book uses images for chapter headings

so I have a book structured like this - where image000r says Chapter 1...
each chapter starts with a h1 tagged image but no text:


<h1 class="calibre10" id="calibre_pb_12"> <a id="_Toc511571660"><img src="../Images/00005.jpeg" alt="" class="calibre11"/></a> </h1>


the next chapter will use images/0006 for chapter 2 etc

if i ask sigil to create a TOC all entries are blank as there is no text for it to use

can anyone suggest a slick tweak so that I can have 1, 2 ,3 ... or chapter 1, chapter 2... etc in a TOC

i could "find" the "5" with regex but I don't know how to do subtraction within regex, so that it can be changed into a 1 when i use replace
stumped is offline   Reply With Quote