![]() |
#1 |
Zealot
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 114
Karma: 6288
Join Date: Dec 2012
Device: iphone
|
TOC Formating
Hi. I'm having fun with Sigil and am just amazed at what it can do. I have run into a problem with the TOC and of course with the html generated TOC.
I have 2 headings. <h4> is the word "Book" and the book number e.g. Book 1 or Book 2 & 2.5 <h3> is the book title The TOC to shows the two headings but they are on 2 different lines which makes the TOC very confusing. Is there any way to get the TOC to show: <h4> <h3> Thank you in advance for your help. |
![]() |
![]() |
![]() |
#2 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Put them together in one <h3>
|
![]() |
![]() |
![]() |
#3 | |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,725
Karma: 8700123
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Quote:
Code:
h3, h4 { display: inline; } Regards Rubén |
|
![]() |
![]() |
![]() |
#4 | |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Quote:
![]() |
|
![]() |
![]() |
![]() |
#5 |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,000
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
I just use Spans insid a single H# to modify one line of text
Code:
<h3 class="chapno">Book<br class="chapspacer" /> <span class="chaptitle">Te Title</span></h3> Book <spaceing> Te Title TOC: Book Th Title |
![]() |
![]() |
![]() |
#6 |
Wizard
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,725
Karma: 8700123
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
|
Watch the epub I attach; watch the TOC.
|
![]() |
![]() |
![]() |
#7 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
|
![]() |
![]() |
![]() |
#8 |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
That is precisely the OP's problem. The ToC is in two parts, since two headers are used.
The appropriate way to do this is with ONE h3/h4 tag, it doesn't matter really which one, but as theducks said, put in a <br/> to split it in the main view into two lines, but the ToC will read it as one header. Styling it for inline takes the problem and makes it worse. Not only is the ToC in two parts (which the OP doesn't want) you have destroyed the whole point of having two header tags, by forcing them to appear on one line. |
![]() |
![]() |
![]() |
#9 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,000
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
When I am done, the Books chapter head looks exactly the same. There is another solution that can be accomplished with a 2 line REGEX capture: <h4> is the word "Book" and the book number e.g. Book (.+?)</h4> <h3>(.+?)</h3) <h4 title="Book \1 - \2">Book \1</h4><h3>\2</h3> |
|
![]() |
![]() |
![]() |
#10 | |
Ex-Helpdesk Junkie
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
|
Quote:
"Styling it for inline ... destroyed the whole point of having two header tags, by forcing them to appear on one line" Sorry for the confusion... I was leaping to your defense, but may not have spoken clearly enough. To clarify: <br/> within a single header tag is awesome, ![]() ![]() |
|
![]() |
![]() |
![]() |
#11 |
Zealot
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 114
Karma: 6288
Join Date: Dec 2012
Device: iphone
|
The problem with putting them in one header (which I hadn't thought of doing by the way) is that the format for them is completely different. So if it reads
Book 1 THE CAT IN THE HAT Both lines are centered Book 1 is in a significantly smaller font and in Proper Capitalization (first letter of every word). The Cat in the Hat is in all caps and underlined. I don't know how to put that in one header. Also a question: if I use the inline method h3, h4 { display: inline; } Where does this go? The TOC Stylesheet? Cause it doesn't look like anything there. Thanks for all of your help Last edited by tarisea; 02-01-2014 at 03:38 PM. Reason: additional question |
![]() |
![]() |
![]() |
#12 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 11,470
Karma: 13095790
Join Date: Aug 2007
Location: Grass Valley, CA
Device: EB 1150, EZ Reader, Literati, iPad 2 & Air 2, iPhone 7
|
Actually you can easily do this with one header. You can center the text and both lines will be centered. A span can be used to change the formatting, even size of characters.
Dale |
![]() |
![]() |
![]() |
#13 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,000
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
the style (class) selector goes on the sheet that is linked. You are formatting the Chapter Head, which is a part of the Body of Work NOT the TOC page, which for convenience in Sigil, has its own stylesheet |
|
![]() |
![]() |
![]() |
Tags |
headings, toc |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Index Formating | tarisea | Sigil | 0 | 01-27-2014 12:24 PM |
Changes in e-book formating | pops1959 | ePub | 2 | 05-03-2011 11:46 AM |
Formating | The Terminator | Amazon Kindle | 11 | 04-01-2011 01:50 PM |
Formating question | crutledge | Sigil | 1 | 05-20-2010 03:11 PM |
PDF Formating | jessie102 | Sony Reader | 0 | 02-09-2010 05:41 PM |