From eccb9abe4aabc25f2a122d2df8e367a9fc9d8342 Mon Sep 17 00:00:00 2001 From: Takeshi KOMIYA Date: Sat, 21 Mar 2020 16:37:34 +0900 Subject: [PATCH] doc: Update about toctree directive --- doc/usage/restructuredtext/directives.rst | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/doc/usage/restructuredtext/directives.rst b/doc/usage/restructuredtext/directives.rst index b5b0a2980..1bb34aeb8 100644 --- a/doc/usage/restructuredtext/directives.rst +++ b/doc/usage/restructuredtext/directives.rst @@ -48,6 +48,11 @@ tables of contents. The ``toctree`` directive is the central element. to the source directory. A numeric ``maxdepth`` option may be given to indicate the depth of the tree; by default, all levels are included. [#]_ + The representation of "TOC tree" is changed in each output format. The + builders that output multiple files (ex. HTML) treat it as a collection of + hyperlinks. On the other hand, the builders output a single file (ex. LaTeX, + man page, etc.) replace it with the content of the documents on the TOC tree. + Consider this example (taken from the Python docs' library reference index):: .. toctree::