2013-02-19 01:53:30 -08:00
|
|
|
|
# -*- coding: utf-8 -*-
|
|
|
|
|
#
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# Configuration file for the Sphinx documentation builder.
|
2013-02-19 01:53:30 -08:00
|
|
|
|
#
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# This file only contains a selection of the most common options. For a full
|
|
|
|
|
# list see the documentation:
|
|
|
|
|
# https://www.sphinx-doc.org/en/master/usage/configuration.html
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
2021-11-17 22:22:27 -08:00
|
|
|
|
# pylint: disable=invalid-name
|
|
|
|
|
|
|
|
|
|
import os
|
|
|
|
|
import sys
|
|
|
|
|
import platform
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
2013-02-19 15:08:42 -08:00
|
|
|
|
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# -- Path setup --------------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
# If extensions (or modules to document with autodoc) are in another directory,
|
|
|
|
|
# add these directories to sys.path here.
|
2021-11-17 22:22:27 -08:00
|
|
|
|
d = 'lib.%s-%s-%d.%d' % (
|
|
|
|
|
platform.system().lower(),
|
|
|
|
|
platform.machine(),
|
|
|
|
|
sys.version_info[0],
|
|
|
|
|
sys.version_info[1]
|
|
|
|
|
)
|
|
|
|
|
sys.path.insert(0, os.path.abspath('../build/' + d))
|
|
|
|
|
# sys.path.insert(0, os.path.abspath('../build/lib.linux-i686-3.2'))
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
2014-08-16 06:42:03 -07:00
|
|
|
|
# Delete any previously imported efl package
|
2021-11-17 22:22:27 -08:00
|
|
|
|
if 'efl' in sys.modules:
|
|
|
|
|
del sys.modules['efl']
|
2014-08-16 06:42:03 -07:00
|
|
|
|
|
2014-04-06 07:17:27 -07:00
|
|
|
|
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# -- Project information -----------------------------------------------------
|
|
|
|
|
|
2021-11-17 22:22:27 -08:00
|
|
|
|
project = 'Python EFL'
|
2021-11-17 22:02:41 -08:00
|
|
|
|
author = 'The Python-EFL community (see AUTHORS)'
|
2022-02-27 10:07:34 -08:00
|
|
|
|
copyright = '2008-2022, ' + author # pylint: disable=redefined-builtin
|
2021-11-17 22:02:41 -08:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# -- General configuration ----------------------------------------------------
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# If your documentation needs a minimal Sphinx version, state it here.
|
2021-11-16 23:50:12 -08:00
|
|
|
|
needs_sphinx = '3.1'
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# Add any Sphinx extension module names here, as strings. They can be extensions
|
|
|
|
|
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
|
2013-02-23 03:18:50 -08:00
|
|
|
|
extensions = [
|
|
|
|
|
'sphinx.ext.autodoc',
|
2013-02-24 05:23:33 -08:00
|
|
|
|
'sphinx.ext.coverage',
|
2013-02-23 03:18:50 -08:00
|
|
|
|
]
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# Add any paths that contain templates here, relative to this directory.
|
|
|
|
|
templates_path = ['_templates']
|
|
|
|
|
|
|
|
|
|
# The master toctree document.
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# master_doc = 'index'
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# List of patterns, relative to source directory, that match files and
|
|
|
|
|
# directories to ignore when looking for source files.
|
|
|
|
|
exclude_patterns = ['_build']
|
|
|
|
|
|
2014-04-06 07:17:27 -07:00
|
|
|
|
|
|
|
|
|
# -- Autodoc configuration -----------------------------------------------------
|
|
|
|
|
|
2021-11-16 23:50:12 -08:00
|
|
|
|
autodoc_default_options = {
|
|
|
|
|
'members': True, # show methods for classes
|
|
|
|
|
'show-inheritance': True, # show bases class
|
|
|
|
|
'member-order': 'alphabetical', # bysource, alphabetical, groupwise
|
|
|
|
|
'no-undoc-members': True, # dont show members without docstring
|
|
|
|
|
'no-inherited-members': True, # dont show members from parent classes
|
|
|
|
|
}
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# both the class’ and the __init__ method’s docstring are concatenated
|
|
|
|
|
autoclass_content = 'both'
|
2014-04-06 07:17:27 -07:00
|
|
|
|
|
|
|
|
|
def setup(app):
|
|
|
|
|
app.connect('autodoc-process-signature', autodoc_process_signature)
|
|
|
|
|
|
2021-11-17 22:22:27 -08:00
|
|
|
|
def autodoc_process_signature(_app, what, _name, _obj, _options, signature, return_annotation):
|
2014-04-06 07:17:27 -07:00
|
|
|
|
"""Cleanup params: remove the 'self' param and all the cython types"""
|
|
|
|
|
|
|
|
|
|
if what not in ('function', 'method'):
|
2021-11-17 22:22:27 -08:00
|
|
|
|
return None
|
2014-04-06 07:17:27 -07:00
|
|
|
|
|
2021-11-17 22:22:27 -08:00
|
|
|
|
params = []
|
2014-04-06 07:17:27 -07:00
|
|
|
|
for param in (p.strip() for p in signature[1:-1].split(',')):
|
|
|
|
|
if param != 'self':
|
|
|
|
|
params.append(param.rpartition(' ')[2])
|
|
|
|
|
|
|
|
|
|
return ('(%s)' % ', '.join(params), return_annotation)
|
|
|
|
|
|
|
|
|
|
|
2015-01-06 11:51:57 -08:00
|
|
|
|
# -- Inheritance Diagram ------------------------------------------------------
|
|
|
|
|
|
|
|
|
|
try:
|
2021-11-17 22:22:27 -08:00
|
|
|
|
import gv # pylint: disable=unused-import
|
2015-01-06 11:51:57 -08:00
|
|
|
|
except ImportError:
|
|
|
|
|
pass
|
|
|
|
|
else:
|
|
|
|
|
extensions.append('sphinx.ext.inheritance_diagram')
|
|
|
|
|
# svg scale better (look at the full elm dia)
|
|
|
|
|
# but svg links are broken :(
|
2021-11-17 23:21:47 -08:00
|
|
|
|
graphviz_output_format = 'png' # png (default) or svg
|
2015-01-06 11:51:57 -08:00
|
|
|
|
inheritance_graph_attrs = dict(
|
2021-11-17 22:22:27 -08:00
|
|
|
|
bgcolor = 'gray25', #404040
|
2015-01-06 11:51:57 -08:00
|
|
|
|
)
|
|
|
|
|
inheritance_node_attrs = dict(
|
2021-11-17 22:22:27 -08:00
|
|
|
|
style = 'rounded', # or 'filled',
|
|
|
|
|
# fillcolor = 'gray20', # bg color (should be #CCCCCC)
|
|
|
|
|
color = 'gray10', # border color (should be #202020)
|
2015-01-06 11:51:57 -08:00
|
|
|
|
fontcolor = 'white',
|
|
|
|
|
font = 'sans',
|
2015-03-04 01:21:59 -08:00
|
|
|
|
|
2015-01-06 11:51:57 -08:00
|
|
|
|
)
|
|
|
|
|
inheritance_edge_attrs = dict(
|
2021-11-17 22:22:27 -08:00
|
|
|
|
color = 'dodgerblue3', # arrow color (should be #4399FF)
|
|
|
|
|
dir = 'none', # arrow direction (back, forward, both or none)
|
2015-01-06 11:51:57 -08:00
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
2013-02-19 01:53:30 -08:00
|
|
|
|
# -- Options for HTML output ---------------------------------------------------
|
|
|
|
|
|
|
|
|
|
# The theme to use for HTML and HTML Help pages. See the documentation for
|
|
|
|
|
# a list of builtin themes.
|
2013-04-04 11:22:56 -07:00
|
|
|
|
#
|
2021-11-17 22:02:41 -08:00
|
|
|
|
# html_theme = 'alabaster' # Default sphinx theme
|
2013-04-04 11:22:56 -07:00
|
|
|
|
# html_theme = 'default' # Classic python style
|
2013-04-30 15:03:40 -07:00
|
|
|
|
# html_theme = 'sphinxdoc' # Much modern sphinx style
|
2013-04-04 12:03:59 -07:00
|
|
|
|
# html_theme = 'sphinx13' # The latest one from the sphinx site
|
2021-11-17 22:02:41 -08:00
|
|
|
|
html_theme = 'efldoc' # Our custom EFL dark style
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# 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 = {}
|
|
|
|
|
|
|
|
|
|
# Add any paths that contain custom themes here, relative to this directory.
|
2013-04-04 12:09:39 -07:00
|
|
|
|
html_theme_path = ['themes']
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# The name for this set of Sphinx documents. If None, it defaults to
|
|
|
|
|
# "<project> v<release> documentation".
|
|
|
|
|
#html_title = None
|
|
|
|
|
|
|
|
|
|
# A shorter title for the navigation bar. Default is the same as html_title.
|
2021-11-17 22:22:27 -08:00
|
|
|
|
html_short_title = 'Python EFL'
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# The name of an image file (relative to this directory) to place at the top
|
|
|
|
|
# of the sidebar.
|
2021-11-17 22:22:27 -08:00
|
|
|
|
html_logo = 'images/logo.png'
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# The name of an image file (within the static path) to use as favicon of the
|
|
|
|
|
# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
|
|
|
|
|
# pixels large.
|
2021-11-17 22:22:27 -08:00
|
|
|
|
html_favicon = 'images/logo.ico'
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# Add any paths that contain custom static files (such as style sheets) here,
|
|
|
|
|
# relative to this directory. They are copied after the builtin static files,
|
|
|
|
|
# so a file named "default.css" will overwrite the builtin "default.css".
|
2013-04-04 04:23:25 -07:00
|
|
|
|
html_static_path = ['images']
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
|
|
|
|
|
# using the given strftime format.
|
2013-04-30 15:03:40 -07:00
|
|
|
|
html_last_updated_fmt = '%b %d, %Y'
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# Custom sidebar templates, maps document names to template names.
|
|
|
|
|
#html_sidebars = {}
|
|
|
|
|
|
|
|
|
|
# Additional templates that should be rendered to pages, maps page names to
|
|
|
|
|
# template names.
|
|
|
|
|
#html_additional_pages = {}
|
|
|
|
|
|
|
|
|
|
# If false, no module index is generated.
|
|
|
|
|
#html_domain_indices = True
|
|
|
|
|
|
|
|
|
|
# If false, no index is generated.
|
|
|
|
|
#html_use_index = True
|
|
|
|
|
|
|
|
|
|
# If true, the index is split into individual pages for each letter.
|
|
|
|
|
#html_split_index = False
|
|
|
|
|
|
|
|
|
|
# If true, links to the reST sources are added to the pages.
|
2013-02-23 03:18:50 -08:00
|
|
|
|
html_show_sourcelink = False
|
2013-02-19 01:53:30 -08:00
|
|
|
|
|
|
|
|
|
# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
|
|
|
|
|
#html_show_sphinx = True
|
|
|
|
|
|
|
|
|
|
# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
|
|
|
|
|
#html_show_copyright = True
|
|
|
|
|
|
|
|
|
|
# If true, an OpenSearch description file will be output, and all pages will
|
|
|
|
|
# contain a <link> tag referring to it. The value of this option must be the
|
|
|
|
|
# base URL from which the finished HTML is served.
|
|
|
|
|
#html_use_opensearch = ''
|
|
|
|
|
|
|
|
|
|
# This is the file name suffix for HTML files (e.g. ".xhtml").
|
|
|
|
|
#html_file_suffix = None
|
|
|
|
|
|
|
|
|
|
# Output file base name for HTML help builder.
|
2013-02-23 03:18:50 -08:00
|
|
|
|
htmlhelp_basename = 'PythonEFLdoc'
|