Changed conf.py to use RTD theme if available

This commit is contained in:
Ryan Gonzalez 2014-04-21 13:47:31 -05:00 committed by Berker Peksag
parent e57047289a
commit 4f8ab5af8c
2 changed files with 8 additions and 1 deletions

View File

@ -96,7 +96,13 @@ pygments_style = 'sphinx'
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'default'
try:
import sphinx_rtd_theme
except ImportError:
html_theme = 'default'
else:
html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the

View File

@ -9,3 +9,4 @@ coverage
# documentation
Pygments>=1.6
Sphinx
sphinx_rtd_theme