TX Text Control .NET Server

TableOfContentsInfo Object

Object|Introduced in 29.0

Description

Information about a table of contents. Is needed by the event argument class TableOfContentsEventArgs.

Syntax

{
   hasLinks: <boolean>,
   hasPageNumbers: <boolean>,
   hasRightAlignedPageNumbers: <boolean>,
   highlightColor: <string>,
   highlightMode: <string>,
   id: <Number>,
   length: <number>,
   maximumStructureLevel: <number>,
   minimumStructureLevel: <number>,
   name: <string>,
   number: <number>,
   start: <number>
}

Examples

The following example demonstrates TableOfContentsInfo in a practical document-editing workflow. Information about a table of contents. Is needed by the event argument class TableOfContentsEventArgs.

function inspectTableOfContentsInfo(tableOfContentsInfo) {
    console.log("has links:", tableOfContentsInfo.hasLinks);
    console.log("has page numbers:", tableOfContentsInfo.hasPageNumbers);
    console.log("has right aligned page numbers:", tableOfContentsInfo.hasRightAlignedPageNumbers);
    console.log("highlight color:", tableOfContentsInfo.highlightColor);
}

Members

Properties

PropertyDescription
hasLinksSpecifies whether each entry in the table of contents is a DocumentLink with a corresponding DocumentTarget.
hasPageNumbersSpecifies whether the table of contents contains page numbers.
hasRightAlignedPageNumbersSpecifies whether the page numbers in the table of contents are right-aligned.
highlightColorThe highlight color for the table of contents.
highlightModeIndicates how the text of the table of contents is highlighted.
idThe table of contents' identifier.
lengthThe number of characters which belong to the table of contents.
maximumStructureLevelThe maximum structure level for this table of contents.
minimumStructureLevelThe minimum structure level for this table of contents.
nameThe table of contents' name.
numberThe table of contents' one-based number in the document.
startThe one-based index of the first character which belongs to the table of contents.