From fd2b27aa063c31258482c9b432c80c98b5a93f07 Mon Sep 17 00:00:00 2001 From: anarcat Date: Mon, 20 Mar 2017 18:03:12 -0400 Subject: add captions to the split toctrees (#3466) * add captions to the split toctrees this will render the table of contents with separators in the RTD theme. right now, the table of contents is quite confusing on the [RTD site][] - that is because there are 3 distinct `toctree` directives, but no `:caption:` field. instead, there are headers in the `index.rst` but those are not parsed by RTD. [RTD site]: https://cryptography.io/en/latest/ by moving those headers in the `:caption:` field, we keep the heading, but it will also be shown in the left table of contents on the RTD site. for an example of that pattern, see the [scrapy documentation][]. they go even further by hiding the `toctree` elements completely and adding explanations on every section, but this is out of scope here for now. [scrapy documentation]: https://doc.scrapy.org/en/latest/index.html * remove spurious backtics in caption they do not work in that field, apparently. --- docs/index.rst | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) (limited to 'docs') diff --git a/docs/index.rst b/docs/index.rst index 5c26a754..9c9ad4a0 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -56,11 +56,9 @@ admonition at the top. We recommend using the recipes layer whenever possible, and falling back to the hazmat layer only when necessary. -The recipes layer -~~~~~~~~~~~~~~~~~ - .. toctree:: :maxdepth: 2 + :caption: The recipes layer fernet x509/index @@ -69,21 +67,17 @@ The recipes layer faq glossary -The hazardous materials layer -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - .. toctree:: :maxdepth: 2 + :caption: The hazardous materials layer hazmat/primitives/index hazmat/backends/index hazmat/bindings/index -The ``cryptography`` open source project -~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ - .. toctree:: :maxdepth: 2 + :caption: The cryptography open source project installation development/index -- cgit v1.2.3