This page is a snippet

For full information, see:

Snippet

 

Macro name: toc

Macro body: None.

Parameter nameRequiredDefaultParameter description and accepted values
printableNotrueIf you set this parameter to false, the table of contents will not be visible when you print the page.
styleNononeThe style of bullet point for each list item. You can use any valid CSS style. For example:
  • none – No list style is displayed.
  • circle –  The list style is a circle.
  • disc – The list style is a filled circle. This is the typical bullet list, and is the one we are using in this example list.
  • square — The list style is a square.
  • decimal — The list is numbered (1, 2, 3, 4, 5).
  • lower-alpha — The list style is lower case, alphabetised (a, b, c, d, e).
  • lower-roman — The list style is lower-case roman numerals (i, ii, iii, iv, v, vi).
  • upper-roman — The list style is upper-case roman numerals (I, II, III, IV, V, VI).
maxLevelNo7Maximum heading level. Use this parameter to select the highest heading level to include.  For example, a value of 2 will list h1 and h2 levels, but will not include h3 and below.
indentNo(None)

This parameter applies to vertical lists only (type = list). 

Use this parameter to indent the list items according to CSS quantities. For example, a value of 10px will successively indent list heading groups by 10 pixels. Level 1 headings will be indented 10px, and level 2 headings by an additional 10px, and so on.

minLevelNo1Minimum heading level. The heading level at which the table of contents will start.  For example, a value of 2 will list h2, h3, and h4 headings, but will not include h1 headings.
classNo(None)A CSS class name. If you have a custom style sheet, you can use this parameter to output the table of contents with the specified class attribute.
excludeNo(None)

Specifies the headings to exclude by pattern matching. The value must be a regular expression. If this parameter is specified, the table of contents will include only the headings that match the regular expression. Example: .*\.[1//2]

 See Sun's Regex documentation for examples of constructing regular expression strings.
typeNolist

Defines the overall format of the table of contents.

Available values:

  • list – displays the table of contents in a vertical list.
  • flat – displays a horizontal series of links. For example: [Heading 1] [Heading 2] [Heading 3].
outlineNofalseA value of true will apply outline numbering to the headings as displayed in the table of contents. For example: 1.1, 1.2, 1.3.
separatorNobrackets

This parameter applies to flat lists only (type = flat).  Use this parameter to style the display of a flat list. 

Available values:

  • brackets – Each item is enclosed by square brackets: [ ].
  • braces  – Each item is enclosed by braces: { }.
  • parens – Each item is enclosed by parentheses: ( ).
  • pipe – The items are separated by a pipe: |
  • anything – The items are separated by the value you enter. You can enter any text as a separator, for example ***. If using a custom separator, be aware that text displays exactly as entered, with no additional white space to further separate the characters.
includeNo(None)

Specifies the headings to include by pattern matching. The value must be a regular expression. If this parameter is specified, the table of contents will ignore any headings that do not match the regular expression. Example: .*\.[1//2]

 See Sun's Regex documentation for examples of constructing regular expression strings.

  • No labels