-1

I have just recently (yesterday) started using sphinx and read the docs for my project.

Till now I am happy with the Html documentation but the pdf version includes all the articles That appear in the index within the Contents heading. And the Documents orignal content/index is simply comprised of two links.

Please help.

The documentation is at http://todx.rtfd.io and the pdf is here.

barryhunter
  • 20,886
  • 3
  • 30
  • 43
Aditya ultra
  • 942
  • 1
  • 8
  • 15

1 Answers1

0

When generating the PDF, Sphinx is always adding the content that is referenced via a .. toctree:: directive exactly where the directive is placed. In contrast, when generating HTML, Sphinx is placing the content after the file that contains the toctree.

In this aspect, PDF generation and HTML generation are simply inconsistent.

Thus, you should place all content of the index page before the table of contents.

In case you want to provide an overview of the most important sections inline, you can use a list of references. Then, you might want to hide the toctree using the hidden property, for example like this:

Contents
--------

- :ref:`quickstart`
- :ref:`userguide`

Features
--------

- Fast
- Simple
- Inituitive
- Easy to Use
- Offline
- Open Source

.. toctree::
   :hidden:

   quickstart
   userguide
Timotheus.Kampik
  • 2,425
  • 1
  • 22
  • 30