View Single Post
Old 09-02-2013, 03:37 PM   #17
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 31,109
Karma: 60406498
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by automa View Post
Also, before automatically putting headings around the chapter titles, how can you make the chapter description in one line with the word "Chapter" so that you can see the description of the chapter in the table of contents, instead of just "Chapter i, chapter ii," etc.
Just use a consistent entry (template) format

eg Heading 3 followed by a Heading 4

<h3> Chapter n
<h4> The chapter title

Then a Search and replace

to turn the 2 into a single with styling


Code:
 replace:
<h3 class="chapter">Chapter  \1 <br class="ctspace" /> <span class="cst">\2<\span><\h3>
the:
.chapter CSS sets the basics of the chapter number
.ctspace sets the spacing between the 2 lines (if inherited is not acceptable)
.cst controls the chapter title

Because you used a BR, the toc (NCX) will use both


In some cases, you might want a different treatment

<h3 title="create your replace template here" > And Leave the original heading text intact
theducks is online now   Reply With Quote