2018-01-29 20:44:03 -05:00
|
|
|
************
|
|
|
|
|
Installation
|
|
|
|
|
************
|
|
|
|
|
|
|
|
|
|
Install the package (or add it to your ``requirements.txt`` file):
|
|
|
|
|
|
2019-07-19 11:35:12 -06:00
|
|
|
.. code:: console
|
2018-01-29 20:44:03 -05:00
|
|
|
|
2019-10-23 11:08:08 -04:00
|
|
|
$ pip install sphinx_rtd_theme
|
2018-01-29 20:44:03 -05:00
|
|
|
|
|
|
|
|
In your ``conf.py`` file:
|
|
|
|
|
|
|
|
|
|
.. code:: python
|
|
|
|
|
|
2019-07-16 20:27:16 -06:00
|
|
|
import sphinx_rtd_theme
|
2018-01-29 20:44:03 -05:00
|
|
|
|
2019-07-16 20:27:16 -06:00
|
|
|
extensions = [
|
|
|
|
|
...
|
|
|
|
|
'sphinx_rtd_theme',
|
|
|
|
|
]
|
2018-01-29 20:44:03 -05:00
|
|
|
|
2019-07-16 20:27:16 -06:00
|
|
|
html_theme = "sphinx_rtd_theme"
|
2018-01-29 20:44:03 -05:00
|
|
|
|
|
|
|
|
|
2019-07-16 20:27:16 -06:00
|
|
|
.. note::
|
|
|
|
|
Adding this theme as an extension is what enables localization of theme
|
|
|
|
|
strings in your translated output. If these strings are not translated in
|
|
|
|
|
your output, either we lack the localized strings for your locale, or you
|
|
|
|
|
are using an old version of the theme.
|
2019-07-19 15:29:24 -06:00
|
|
|
|
|
|
|
|
Via Git or Download
|
|
|
|
|
===================
|
|
|
|
|
|
|
|
|
|
Symlink or subtree the ``sphinx_rtd_theme/sphinx_rtd_theme`` repository into your documentation at
|
|
|
|
|
``docs/_themes/sphinx_rtd_theme`` then add the following two settings to your Sphinx
|
|
|
|
|
``conf.py`` file:
|
|
|
|
|
|
|
|
|
|
.. code:: python
|
|
|
|
|
|
|
|
|
|
html_theme = "sphinx_rtd_theme"
|
|
|
|
|
html_theme_path = ["_themes", ]
|