View Single Post
Old 07-30-2020, 11:50 PM   #4
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Could be useful.
What I've been doing when I have chapters like:


<h1>Chapter 4</h1>
<h2>Whatever happens</h2>


is use regex to make it
<h1>Chapter 4<br/>
<span class="chapsub">Whatever happens</span></h1>


Before I do "generate TOC" I convert
<br/>
<span class="chapsub">


to :<br/>
<span class="chapsub">


So I get
Chapter 4: Whatever happens
in the toc file. Then I delete the colon from the chapter files.

I'll still do this when there are other levels of heading (e.g. "Parts" ) that I want to retain, but if there are just chapters this might be simpler.
AlanHK is offline   Reply With Quote