主题
内置主题
sphinx
提供了多种内置主题,当前默认主题是alabaster
,还有其他的主题 - builtin-themes
主题替换
修改conf.py
中的html_theme
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
# html_theme = 'alabaster'
html_theme = 'sphinx_rtd_theme'
修改成了readthedocs
主题风格,它需要先自行安装
pip install -U sphinx_rtd_theme
主题自定义
sphinx
也支持自定义主题,或者对当前主题进行微调 - using-a-theme