Post amended: 17 August 2019, to include the autogeneration of a ToC!
An ebook needs a dynamic contents list
The process of setting up a table of contents (TOC) is straightforward!
First, you have two choices:
- Let Scrivener do it for you
- Do it yourself
Letting Scrivener do it for you
When you choose ebook from the output options, an additional icon appears in the right-hand pane. The default setting is that Scrivener generates the ToC page for you with the title ‘Contents’.
Try this (without making any changes to the default settings) and see what you think of the ebook Scrivener produces.
I prefer to generate my own ToC, so I uncheck the ‘Generate HTML table of contents’ box and use the DIY method below.
Doing it yourself
Step 1: Decide what is to appear
Your aim is to set up the Binder so it shows whatever you want to appear in the content list.
Bear in mind that each entry will form a hyperlink, so be as helpful to your reader by providing a clear view of the structure of your book.
Expand/collapse folders to suit yourself – and your readers – and then, select them all as shown in the image.
NB: Don’t include the Contents!
Step 2: Create the contents list on the clipboard
Having set up the Binder as you wish, and selected the relevant entries, select Edit / Copy Special / Copy Documents as ToC.
Step 3: Paste the ToC into the Contents document
I already had a document called Contents, so I Selected All before I pasted the new ToC into place.
Step 4: Choose the Table of Contents settings
As soon as you paste the ToC into place, Scrivener presents you with this pane. I didn’t argue! Click Ok.
This is what then appeared. The <$p> at the end of each line are for the page numbers which would be automatically calculated during the compile process.
For an eBook, the page numbers are not needed, so delete them all, leaving just the hyperlinks for the titles of your documents. It should look like this before you compile.
And, when you compile …
You might be tempted to add more detail to the contents list, or take some material out, to make it fit better on a page. However, remember that the reader decides on the page size. Best to leave well alone. It works, and that’s enough.
Questions? Need a helping hand? Want a demo?
To watch me demonstrating how to set up the ToC for an ebook or to ask any questions, book a place at the next Simply Scrivener Special. 60 minutes of Q&A on Scrivener with me, Anne Rainbow, ScrivenerVirgin!
To help me prepare, you could also complete this short questionnaire.
The ScrivenerVirgin blog is a journey of discovery:
a step-by-step exploration of how Scrivener can change how a writer writes.
To subscribe to this blog, click here.
Also … check out the Scrivener Tips
on my ScrivenerVirgin Facebook page.