doc: add some Pybricks branding

This adds some Pybricks logos to the the generated docs .

The actual logos are quick hacks and should be revisited.
This commit is contained in:
David Lechner
2019-01-20 19:10:26 -06:00
parent 48d795ea08
commit cbefc64136
3 changed files with 13 additions and 4 deletions
+13 -4
View File
@@ -21,10 +21,15 @@ import os
import sys
sys.path.insert(0, os.path.abspath('../../lib/fake-pybricks/pybricks'))
import _version
import _version # noqa E402
# on_rtd is whether we are on readthedocs.org, this line of code grabbed from docs.readthedocs.org
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
# ON_RTD is whether we are on readthedocs.org
# this line of code grabbed from docs.readthedocs.org
ON_RTD = os.environ.get('READTHEDOCS', None) == 'True'
# branding
LOGO_SMALL = os.environ.get('PYBRICKS_LOGO_SMALL', 'images/pybricks-logo-small.png')
LOGO_LARGE = os.environ.get('PYBRICKS_LOGO_LARGE', 'images/pybricks-logo-large.png')
# -- General configuration ------------------------------------------------
@@ -96,7 +101,7 @@ add_module_names = False # Hide module name
# -- Options for HTML output ----------------------------------------------
if on_rtd:
if ON_RTD:
html_theme = 'default'
html_context = {
'css_files': [
@@ -115,6 +120,8 @@ else:
],
}
html_logo = LOGO_SMALL
# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
@@ -181,6 +188,8 @@ latex_documents = [
'Laurens Valk, David Lechner', 'manual'),
]
latex_logo = LOGO_LARGE
# -- Options for manual page output ---------------------------------------
Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB