I'm writing a sphinx documentation for use in generating both html and latex output.
Some of my rst
files are structured as follows:
My chapter title
=====================
.. toctree::
:hidden:
:maxdepth: 2
folder/subchapter1
folder/subchapter2
Chapter introduction
--------------------------
Brief introduction...
This works as intended in my html output - but for my latex build, I'm getting the following order when building my pdf:
My chapter title
subchapter1
[contents of subchapter 1]
subchapter2
[contents of subchapter 2]
Chapter introduction
Brief introduction...
The intended order would be as below:
My chapter title
Chapter introduction
Brief introduction...
subchapter1
[contents of subchapter 1]
subchapter2
[contents of subchapter 2]
Is there some way to tell sphinx via the conf.py
that this should be the ordering?