View Single Post
Old 07-31-2020, 06:26 AM   #6
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,737
Karma: 24031401
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by AlanHK View Post
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>
IMHO, it'd more efficient, if you used a regex to convert the heading to:

Code:
<h1 title="Chapter 4: Whatever happens">Chapter 4<br/>
<span class="chapsub">Whatever happens</span></h1>
Since Sigil will use title attributes to generate the TOC, you could simply re-generate the TOC without having to add/remove colons.
Doitsu is offline   Reply With Quote