InDesign Server2025
API 20.5.0.49
Object

TOCStyle

A TOC style definition.

Hierarchy

Document

TOCStyle

TOCStyleEntry

Properties

NameType AccessDescription
Boolean read/write If true, creates bookmarks for TOC entries.
EventListeners<EventListener> readonly A collection of event listeners.
Events<Event> readonly A collection of events.
Number readonly The unique ID of the TOCStyle.
Boolean read/write If true, includes the entire book in the TOC. If false, includes only the TOC entries in the current document. Note: Valid when the current document is part of a book.
Boolean read/write If true, the TOC includes entries from text on hidden layers.
Number readonly The index of the TOCStyle within its containing object.
Boolean readonly Returns true if the object specifier resolves to valid objects.
String read/write A property that can be set to any string.
Boolean read/write If true, make text anchor in source paragraph.
String read/write The name of the TOCStyle.
NumberedParagraphsOptions
read/write The format for importing numbered paragraphs into the TOC.
Document readonly The parent of the TOCStyle (a Document).
Object read/write A property that allows setting of several properties at the same time.
Boolean read/write If true, remove forced line breaks.
Boolean read/write If true, the lowest-level TOC entries are placed on the same line as the previous entry.
HorizontalOrVertical
read/write The table of contents story direction.
String read/write The TOC title.
ParagraphStyle read/write The paragraph style applied to the TOC title.
TOCStyleEntries<TOCStyleEntry> readonly A collection TOC style entries.

Methods

EventListener

Adds an event listener.

eventType String The event type.
handler File | JavaScriptFunction The event handler. Can accept: File or JavaScript Function.
captures? Boolean This parameter is obsolete.
TOCStyle

Duplicates the TOCStyle.

String

Gets the label value associated with the specified key.

key String The key.
TOCStyle[]

Resolves the object specifier, creating an array of object references.

void

Sets the label to the value associated with the specified key.

key String The key.
value String The value.
void

Deletes the TOCStyle.

Boolean

Removes the event listener.

eventType String The registered event type.
handler File | JavaScriptFunction The registered event handler. Can accept: File or JavaScript Function.
captures? Boolean This parameter is obsolete.
String

Generates a string which, if executed, will return the TOCStyle.

String

Retrieves the object specifier.

Object of 4

Properties elsewhere that hold a TOCStyle.

Parameter of 4

Method parameters that accept a TOCStyle.

Return 15

Methods that return a TOCStyle.