About Arbortext Styler > Working with Tables of Contents > Creating a Basic Table of Contents Format Object
  
Creating a Basic Table of Contents Format Object
Table of content format objects are created and managed via the Tables of Contents list The Table of Contents list icon - horizontal lines of varying widths on a grey background. Note that if you select this menu option when any other list is active, you will be taken to the Tables of Contents list.
The procedure detailed below describes the steps involved in creating your table of contents format object:
1. In the Tables of Contents list, click Insert > Table of Contents. A new table of contents format object is added to the list, with the name TableOfContents.
2. Click the object again and rename it as required. You will see a message asking you to confirm that you wish to rename the object, since the name change will filter through to all references in all modules of the stylesheet. Click OK to complete the rename action.
3. In the Scope field, set the element level for which the table of contents should apply, or leave the default setting of Whole Document to create a document level table of contents.
4. Elect whether the table of contents object will contribute entries to PDF Bookmark or online TOCs:
PDF output: check the Use for PDF bookmarks option to specify that entries from this table of contents format object are to be included as bookmarks in PDF output
Chunked HTML output: check the Use for Chunked HTML outputs (EPUB, HTML Help, and Web) option to specify that entries from this table of contents format object are to be included in the online TOC in chunked HTML output
Note that table of contents format objects may also be included as inline TOCs, as described in Styling an Element to Generate a Table of Contents. A single table of contents format object may be included in more than one location. If more than one object is selected to be included as a PDF bookmark or online TOC in chunked HTML output, all the entries from the different objects will be merged, and any duplicates removed.
5. Set the types of title that should be extracted from the document as entries for the table of contents - as a general setting you can elect to include all division titles configured for your stylesheet, by checking the Division titles option. You can also click the Customize button to open the Customize Table of Contents dialog box, where you can individually select the element contexts that should form each level of your TOC. In the list you will see all elements that have the Title style applied in the stylesheet.
From this dialog box you may also configure any custom numbering or generated text that should be applied to each entry. See Customizing the Content of a TOC for further information.
6. If you have elected to include Division titles in your table of contents, set the level to which the table of contents will reach in the Number of levels field. The range is 1 to 10; with 3 being the default. The levels refer to the hierarchical elements that have been assigned the Division style. For example, if you have only mapped the chapter element to the Division style only the chapter titles will appear in the table of contents, even if you choose to display 3 levels. If, on the other hand, you have applied the Division style to the chapter, sect1, sect2, sect3, and sect4 elements, then you need a setting of 5 levels to produce a table of contents that includes all these elements.
Note that any include/exclude settings made for division titles in the Customize Table of Contents dialog box will override the level setting here. See Customize Table of Contents Dialog Box for further information.
7. Click the Format... button to open the Table of Contents Format dialog box, where you can define the display of your TOC.
When you have finished setting up your table of contents format object, you can include it in several locations:
To generate an inline TOC: reference the table of contents format object from an element given the Table of Contents style in the Elements list. The selected element will produce the table of content as its generated text. See Styling an Element to Generate a Table of Contents for further information.
To contribute its entries as bookmarks in PDF output - ensure the Use for PDF bookmarks option is selected for the object in step 4
To contribute its entries in an online TOC for chunked HTML outputs- ensure the Use for Chunked HTML outputs (EPUB, HTML Help, and Web) option is selected for the object in step 4