docs: use custom html theme

This uses the new custom HTML theme for Sphinx, so our documentation
looks similar to our website.

Reviewed-by: Eric Engestrom <eric@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/8399>
This commit is contained in:
Erik Faye-Lund
2021-01-21 15:11:24 +01:00
committed by Marge Bot
parent 3b6f549e96
commit 9aefd97cfd
3 changed files with 4 additions and 32 deletions

View File

@@ -1,8 +1,6 @@
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
import sphinx_rtd_theme
#
# The Mesa 3D Graphics Library documentation build configuration file, created by
# sphinx-quickstart on Wed Mar 29 14:08:51 2017.
@@ -39,6 +37,7 @@ sys.path.append(os.path.abspath('_exts'))
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'bootstrap',
'breathe',
'formatting',
'nir',
@@ -64,7 +63,7 @@ copyright = '1995-2018, Brian Paul'
author = 'Brian Paul'
html_show_copyright = False
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
html_theme_path = ['.']
# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
@@ -87,9 +86,6 @@ language = 'en'
# This patterns also effect to html_static_path and html_extra_path
exclude_patterns = []
# The name of the Pygments (syntax highlighting) style to use.
pygments_style = 'sphinx'
# If true, `todo` and `todoList` produce output, else they produce nothing.
todo_include_todos = False
@@ -104,27 +100,10 @@ default_role = 'c:expr'
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'sphinx_rtd_theme'
html_theme = 'mesa3d_theme'
html_favicon = 'favicon.ico'
# 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
# documentation.
#
html_theme_options = {
'display_version': False,
}
html_context = {
'display_gitlab': True,
'gitlab_host': 'gitlab.freedesktop.org',
'gitlab_user': 'mesa',
'gitlab_repo': 'mesa',
'gitlab_version': 'main',
'conf_py_path': '/docs/',
}
html_copy_source = False
# Add any paths that contain custom static files (such as style sheets) here,

View File

@@ -10,7 +10,7 @@
- public/
script:
- apk --no-cache add graphviz doxygen
- pip3 install sphinx===5.1.1 breathe===4.34.0 mako===1.2.3 sphinx_rtd_theme===1.0.0
- pip3 install sphinx===5.1.1 breathe===4.34.0 mako===1.2.3
- docs/doxygen-wrapper.py --out-dir=docs/doxygen_xml
- sphinx-build -W -b $BUILDER docs public

View File

@@ -137,10 +137,3 @@ Linux, FreeBSD, and other operating systems.
OpenGL Website <https://www.opengl.org>
DRI Website <https://dri.freedesktop.org>
Developer Blogs <https://planet.freedesktop.org>
.. toctree::
:maxdepth: 1
:caption: Hosted by:
:hidden:
freedesktop.org <https://www.freedesktop.org>