InDesign CS4 for Macintosh and Windows: Visual QuickStart Guide

InDesign creates a table of contents (TOC) by looking at the styles applied to paragraphs and then listing the text and page numbers for those paragraphs. The TOC for this book lists the chapters and the section heads .

The paragraph styles applied to chapter titles and section heads in this book can be used to create a table of contents.

To prepare a document for a table of contents:

1.

Add the page or pages that will hold the TOC.

Tip

Most tables of contents are part of the frontmatter of a book and are numbered separately without affecting the regular page numbering.

Tip

If the document is part of a book, make sure the book's pagination is current.

2.

Apply paragraph styles to the paragraphs that you want to appear in the TOC. (See page 368 for more information on paragraph styles.)

To define the styles for TOC entries:

1.

Choose Layout > Table of Contents to open the Table of Contents dialog box .

The Table of Contents dialog box lets you select and format listings for a table of contents.

2.

Set the Title and Listing controls as described in the exercises that start on the next page.

3.

Click Save Style. This opens the Save Style dialog box .

The Save Style dialog box lets you save the settings from the Table of Contents dialog box.

4.

Name the style and click Save.

To generate the TOC:

1.

Choose Layout > Table of Contents to open the Table of Contents dialog box.

2.

Set each of the controls as described in the following exercises.

3.

Click OK. This closes the dialog box and creates a loaded text cursor that contains the TOC.

4.

Click or drag the loaded cursor to apply the TOC text where you want it to appear in the document.

Benefits of an Automatic TOC

If all this seems like too much work just to create a short table of contents, you may be tempted to create one by hand manually entering the items in the TOC.

For instance, I could easily create the TOC for this book by hand.

But there is a big benefit in creating an automatic TOC. When you export PDF files with an automatically created TOC, they will have hyperlinks from the TOC to the document pages. (See Chapter 18, "Interactive PDF Elements," for more information on adding hyperlinks and other interactive elements to InDesign files.)

This means someone reading the PDF document can just click on the page number listed in the TOC to go to that specific page. Without the electronic TOC, you'd have to manually add all those links in Acrobat.

The title is the label that is applied before each entry in the table of contents. You can set the type for the title as well as the paragraph style that formats the title.

To enter the title of the table of contents:

1.

Type the text for the title in the Title field .

Use the Title field in the Table of Contents dialog box to enter the text you want to appear before the listings.

2.

Use the Style menu to the right of the Title field to choose which paragraph style is applied to format the title.

You choose the entries for a table of contents by selecting the paragraph style sheets that were applied to those sections of your documents.

To choose the listings for the table of contents:

1.

Select a paragraph style listed in the Other Styles area of the Table of Contents dialog box .

Move styles from the Other Styles list to the Include Paragraph Styles list to choose which paragraphs are added to the table of contents.

2.

Click the Add button. This moves the style to the Include Paragraph Styles list.

3.

Repeat steps 1 and 2 for any additional styles.

Most likely you will want to format the entries in a table of contents with a different style than the one used within the document.

To format the entries in the table of contents:

1.

Select the entry listing in the Include Paragraph Styles area.

2.

Choose a paragraph style sheet from the Entry Style menu under the Style: [Name] in the Table of Contents dialog box .

Use the Entry Style menu to choose a style sheet that you have created to format the listing as it should appear in the table of contents.

3.

Repeat steps 1 and 2 for any additional styles.

The Table of Contents dialog box has additional controls for more advanced options such as formatting the page numbers for each entry.

To open the additional table of contents controls:

  • Click the More Options button in the Table of Contents dialog box . This opens the advanced options at the bottom of the dialog box .

    Click the More Options button to expand the controls in the Table of Contents dialog box.

    The Table of Contents dialog box with all the options available.

    Tip

    If the button says Fewer Options, then the dialog box already shows the advanced options.

Other Uses for a Table of Contents

You're not limited to using the Table of Contents commands just for listings of chapters and section heads.

If you have a sales catalog you can use the commands to create a list of all the items, which can be used as a price list. I could generate a separate file for this book that lists all the titles for sidebars such as this one. In a book of illustrations, you can use it to create a list of names of all the artists for each illustration.

The only thing you need to remember is to assign a style sheet to each item that you want to appear in the table of contents.

With the advanced options open, you have additional controls for the style for each entry in the TOC . This gives you greater control over where the page numbers appear and how they are formatted.

The Style options area gives you controls to format how the entries are formatted and arranged in the TOC.

To set the advanced Style options for each entry:

1.

Choose one of the styles in the Include Paragraph Styles list (on page 368). The style name appears in the Style options area.

2.

If you have not already applied a listing from the Entry Style menu, do so as explained on the previous page.

3.

Use the Page Number menu to choose a position for the entry's page number :

The Page Number menu controls where the page number will appear in the TOC listings.

  • After Entry positions the number after the entry.

  • Before Entry positions the number before the entry.

  • No Page Number lists the entry without any page number.

4.

If desired, choose a character style for the page number from the Style list to the right of the Page Number menu.

Tip

The character style lets you apply formatting to the page number for each entry. (See page 375 for working with character styles.)

You can also control how the entry name and the page number are separated from each other.

To control the separator character:

1.

Select one of the character options from the Between Entry and Number menu . The character symbol appears in the field.

2.

If you want, type additional text before or after the character symbol. This lets you add a label before the page number.

3.

If desired, apply a style from the Style menu for the Between Entry and Number character .

A table of contents doesn't have to be organized in the order that the items appear.

To alphabetize the table of contents:

  • Check Sort Entries in Alphabetical order from the advanced options area .

To indent the entries in a table of contents:

  • Use the Level controls to indent each table of contents entry .

    Tip

    Each entry in the Include Paragraph Styles list is automatically indented. This is for display purposes in that dialog box and does not affect the final TOC.

There are additional options you can set for a table of contents .

The TOC Options area lets you control more of the table of contents.

To set the table of contents options:

  • Select each of the table of contents options at the bottom of the Table of Contents dialog box as follows:

    • Create PDF Bookmarks adds bookmarks to the PDF that is created from the TOC. This is in addition to any hyperlinks within the TOC.

    • Replace Existing Table of Contents lets you update or change the table of contents that has already been placed in the document.

    Tip

    This option is only available if a table of contents has already been generated.

    • Include Book Documents lets you create a table of contents for all the documents in a book.

    • Run-in creates a single paragraph table of contents with each entry divided by a semicolon (;) and a space.

    • Include Text on Hidden Layers uses text that is on layers that are not visible. (See the sidebar on this page to see how option this could be used.)

A TOC of Nonexisting Items

The following tip comes from Real World InDesign CS2, by Olav Martin Kvern and David Blatner (Peachpit Press, copyright 2006). I strongly recommend this book for anyone who wants a deeper understanding of InDesign.

The items in a TOC don't have to be from items that are visible on each page. For instance, let's say you want a list of all photographers in your book and where their pictures appear. Simply put the names of the photographers next to their photos, but set the names to not print (see page 460) or on a layer set to not print (see page 293).

Then, run the TOC for the items. You get a list of the photographers' names, even though those names don't actually appear on the printed pages.

Категории