From 9aefd97cfd095d3c03f2e2d69852dd39ecf1ac44 Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Thu, 21 Jan 2021 15:11:24 +0100 Subject: [PATCH] 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 Part-of: --- docs/conf.py | 27 +++------------------------ docs/gitlab-ci.yml | 2 +- docs/index.rst | 7 ------- 3 files changed, 4 insertions(+), 32 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index edee6d9..75c2892 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -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, diff --git a/docs/gitlab-ci.yml b/docs/gitlab-ci.yml index ba4527a..b08c060 100644 --- a/docs/gitlab-ci.yml +++ b/docs/gitlab-ci.yml @@ -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 diff --git a/docs/index.rst b/docs/index.rst index 8b468ef..30b333d 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -137,10 +137,3 @@ Linux, FreeBSD, and other operating systems. OpenGL Website DRI Website Developer Blogs - -.. toctree:: - :maxdepth: 1 - :caption: Hosted by: - :hidden: - - freedesktop.org -- 2.7.4