|
11 | 11 | # All configuration values have a default; values that are commented out |
12 | 12 | # serve to show the default. |
13 | 13 |
|
| 14 | +import os |
| 15 | +import sys |
| 16 | + |
14 | 17 | # If extensions (or modules to document with autodoc) are in another directory, |
15 | 18 | # add these directories to sys.path here. If the directory is relative to the |
16 | 19 | # documentation root, use os.path.abspath to make it absolute, like shown here. |
17 | | -# |
18 | | -import os |
19 | | -import sys |
20 | | -sys.path.insert(0, os.path.abspath('../')) |
| 20 | +sys.path.insert(0, os.path.abspath("../")) |
21 | 21 |
|
22 | 22 | # -- General configuration ------------------------------------------------ |
23 | 23 |
|
24 | 24 | # If your documentation needs a minimal Sphinx version, state it here. |
25 | | -# |
26 | | -# needs_sphinx = '1.0' |
| 25 | +needs_sphinx = "1.4" |
27 | 26 |
|
28 | 27 | # Add any Sphinx extension module names here, as strings. They can be |
29 | 28 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom |
30 | 29 | # ones. |
31 | 30 | extensions = [ |
32 | | - 'sphinx.ext.autodoc', |
33 | | - 'sphinx.ext.todo', |
34 | | - 'sphinx.ext.coverage', |
35 | | - 'sphinx.ext.mathjax', |
36 | | - 'sphinx.ext.viewcode', |
37 | | - 'sphinx.ext.githubpages', |
38 | | - 'sphinx.ext.napoleon' |
| 31 | + "sphinx.ext.autodoc", |
| 32 | + "sphinx.ext.autosummary", |
| 33 | + "sphinx.ext.coverage", |
| 34 | + "sphinx.ext.githubpages", |
| 35 | + "sphinx.ext.mathjax", |
| 36 | + "sphinx.ext.napoleon", |
| 37 | + "sphinx.ext.todo", |
| 38 | + "sphinx.ext.viewcode", |
39 | 39 | ] |
40 | 40 |
|
41 | 41 | # Add any paths that contain templates here, relative to this directory. |
42 | | -templates_path = ['_templates'] |
| 42 | +templates_path = ["_templates"] |
43 | 43 |
|
44 | 44 | # The suffix(es) of source filenames. |
45 | 45 | # You can specify multiple suffix as a list of string: |
46 | 46 | # |
47 | 47 | # source_suffix = ['.rst', '.md'] |
48 | | -source_suffix = '.rst' |
| 48 | +source_suffix = ".rst" |
49 | 49 |
|
50 | 50 | # The encoding of source files. |
51 | 51 | # |
52 | 52 | # source_encoding = 'utf-8-sig' |
53 | 53 |
|
54 | 54 | # The master toctree document. |
55 | | -master_doc = 'index' |
| 55 | +master_doc = "index" |
56 | 56 |
|
57 | 57 | # General information about the project. |
58 | | -project = 'Sound Field Analysis toolbox for Python' |
59 | | -copyright = '2016, Christoph Hohnerlein (QU Lab)' |
60 | | -author = 'Christoph Hohnerlein (QU Lab)' |
| 58 | +project = "Sound Field Analysis toolbox for Python" |
| 59 | +author = ( |
| 60 | + "Christoph Hohnerlein (QU Labs) \\and " |
| 61 | + "Jens Ahrens (Chalmers) \\and " |
| 62 | + "Hannes Helmholz (Chalmers)" |
| 63 | +) |
| 64 | +# noinspection PyShadowingBuiltins |
| 65 | +copyright = "2020, Chalmers University of Technology" |
61 | 66 |
|
62 | 67 | # The version info for the project you're documenting, acts as replacement for |
63 | 68 | # |version| and |release|, also used in various other places throughout the |
64 | 69 | # built documents. |
65 | 70 | # |
66 | 71 | # The short X.Y version. |
67 | | -version = '0.3' |
| 72 | +version = ( |
| 73 | + open("../sound_field_analysis/_version.py").readlines()[-1].split()[-1].strip("\"'") |
| 74 | +) |
68 | 75 | # The full version, including alpha/beta/rc tags. |
69 | | -release = '0.3' |
| 76 | +release = version |
70 | 77 |
|
71 | 78 | # The language for content autogenerated by Sphinx. Refer to documentation |
72 | 79 | # for a list of supported languages. |
|
87 | 94 | # List of patterns, relative to source directory, that match files and |
88 | 95 | # directories to ignore when looking for source files. |
89 | 96 | # This patterns also effect to html_static_path and html_extra_path |
90 | | -exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store'] |
| 97 | +exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] |
91 | 98 |
|
92 | 99 | # The reST default role (used for this markup: `text`) to use for all |
93 | 100 | # documents. |
94 | 101 | # |
95 | 102 | # default_role = None |
96 | 103 |
|
97 | 104 | # If true, '()' will be appended to :func: etc. cross-reference text. |
98 | | -# |
99 | | -# add_function_parentheses = True |
| 105 | +add_function_parentheses = True |
100 | 106 |
|
101 | 107 | # If true, the current module name will be prepended to all description |
102 | 108 | # unit titles (such as .. function::). |
103 | | -# |
104 | | -# add_module_names = True |
| 109 | +add_module_names = True |
105 | 110 |
|
106 | 111 | # If true, sectionauthor and moduleauthor directives will be shown in the |
107 | 112 | # output. They are ignored by default. |
108 | 113 | # |
109 | 114 | # show_authors = False |
110 | 115 |
|
111 | 116 | # The name of the Pygments (syntax highlighting) style to use. |
112 | | -pygments_style = 'sphinx' |
| 117 | +pygments_style = "sphinx" |
113 | 118 |
|
114 | 119 | # A list of ignored prefixes for module index sorting. |
115 | | -# modindex_common_prefix = [] |
| 120 | +modindex_common_prefix = ["sound_field_analysis."] |
116 | 121 |
|
117 | 122 | # If true, keep warnings as "system message" paragraphs in the built documents. |
| 123 | +# |
118 | 124 | # keep_warnings = False |
119 | 125 |
|
| 126 | +# A list of warning types to suppress arbitrary warning messages. |
| 127 | +# |
| 128 | +# suppress_warnings = ["image.not_readable"] |
| 129 | + |
| 130 | +# This value selects if automatically documented members are sorted alphabetical |
| 131 | +# (value 'alphabetical'), by member type (value 'groupwise') or by source order |
| 132 | +# (value 'bysource'). The default is alphabetical. |
| 133 | +autodoc_member_order = "bysource" |
| 134 | + |
120 | 135 | # If true, `todo` and `todoList` produce output, else they produce nothing. |
121 | 136 | todo_include_todos = True |
122 | 137 |
|
123 | 138 | # -- Napoleon settings ---------------------------------------------- |
124 | 139 | napoleon_google_docstring = False |
125 | 140 | napoleon_numpy_docstring = True |
| 141 | +napoleon_include_init_with_doc = True |
126 | 142 | napoleon_include_private_with_doc = False |
127 | 143 | napoleon_include_special_with_doc = True |
128 | | -napoleon_use_admonition_for_examples = False |
129 | | -napoleon_use_admonition_for_notes = False |
130 | | -napoleon_use_admonition_for_references = False |
| 144 | +napoleon_use_admonition_for_examples = True |
| 145 | +napoleon_use_admonition_for_notes = True |
| 146 | +napoleon_use_admonition_for_references = True |
131 | 147 | napoleon_use_ivar = False |
132 | | -napoleon_use_param = True |
133 | | -napoleon_use_rtype = True |
| 148 | +napoleon_use_param = False |
| 149 | +napoleon_use_rtype = False |
134 | 150 |
|
135 | 151 | # -- Options for HTML output ---------------------------------------------- |
136 | 152 |
|
137 | 153 | # The theme to use for HTML and HTML Help pages. See the documentation for |
138 | 154 | # a list of builtin themes. |
139 | 155 | # |
140 | | -html_theme = 'sphinx_rtd_theme' |
| 156 | +html_theme = "sphinx_rtd_theme" |
141 | 157 |
|
142 | 158 | # Theme options are theme-specific and customize the look and feel of a theme |
143 | 159 | # further. For a list of options available for each theme, see the |
144 | 160 | # documentation. |
145 | | -# |
146 | | -# html_theme_options = {} |
| 161 | +html_theme_options = { # Toc options |
| 162 | + "display_version": True, |
| 163 | + "collapse_navigation": False, |
| 164 | + "sticky_navigation": True, |
| 165 | + "navigation_depth": -1, |
| 166 | + "includehidden": True, |
| 167 | + "titles_only": False, |
| 168 | +} |
147 | 169 |
|
148 | 170 | # Add any paths that contain custom themes here, relative to this directory. |
149 | | -html_theme_path = ["_themes", ] |
| 171 | +html_theme_path = [ |
| 172 | + "_themes", |
| 173 | +] |
150 | 174 |
|
151 | 175 | # The name for this set of Sphinx documents. |
152 | 176 | # "<project> v<release> documentation" by default. |
|
171 | 195 | # Add any paths that contain custom static files (such as style sheets) here, |
172 | 196 | # relative to this directory. They are copied after the builtin static files, |
173 | 197 | # so a file named "default.css" will overwrite the builtin "default.css". |
174 | | -html_static_path = ['_static'] |
| 198 | +# |
| 199 | +# html_static_path = ["_static"] |
175 | 200 |
|
176 | 201 | # Add any extra paths that contain custom files (such as robots.txt or |
177 | 202 | # .htaccess) here, relative to this directory. These files are copied |
|
236 | 261 | # Sphinx supports the following languages: |
237 | 262 | # 'da', 'de', 'en', 'es', 'fi', 'fr', 'h', 'it', 'ja' |
238 | 263 | # 'nl', 'no', 'pt', 'ro', 'r', 'sv', 'tr', 'zh' |
239 | | -# |
240 | | -# html_search_language = 'en' |
| 264 | +html_search_language = "en" |
241 | 265 |
|
242 | 266 | # A dictionary with options for the search language support, empty by default. |
243 | 267 | # 'ja' uses this config value. |
|
256 | 280 | # -- Options for LaTeX output --------------------------------------------- |
257 | 281 |
|
258 | 282 | latex_elements = { |
259 | | - # The paper size ('letterpaper' or 'a4paper'). |
260 | | - 'papersize': 'a4paper', |
261 | | - |
262 | | - # Remove blank pages |
263 | | - 'classoptions': ',openany,oneside', |
264 | | - 'babel': '\\usepackage[english]{babel}', |
265 | | - |
266 | | - # The font size ('10pt', '11pt' or '12pt'). |
267 | | - # |
268 | | - # 'pointsize': '10pt', |
269 | | - |
270 | | - # Additional stuff for the LaTeX preamble. |
271 | | - # |
272 | | - # 'preamble': '', |
273 | | - |
274 | | - # Latex figure (float) alignment |
275 | | - # |
276 | | - # 'figure_align': 'htbp', |
| 283 | + # The paper size ('letterpaper' or 'a4paper'). |
| 284 | + "papersize": "a4paper", |
| 285 | + # Remove blank pages |
| 286 | + "classoptions": ",openany,oneside", |
| 287 | + "babel": "\\usepackage[english]{babel}", |
| 288 | + # The font size ('10pt', '11pt' or '12pt'). |
| 289 | + "pointsize": "10pt", |
| 290 | + # Additional stuff for the LaTeX preamble. |
| 291 | + # 'preamble': '', |
| 292 | + # Latex figure (float) alignment |
| 293 | + # 'figure_align': 'htbp', |
277 | 294 | } |
278 | 295 |
|
279 | 296 | # Grouping the document tree into LaTeX files. List of tuples |
280 | 297 | # (source start file, target name, title, |
281 | 298 | # author, documentclass [howto, manual, or own class]). |
282 | 299 | latex_documents = [ |
283 | | - (master_doc, 'sfa_readme.tex', 'Sound Field Analysis Toolbox Readme', |
284 | | - 'Christoph Hohnerlein (QU Lab)', 'manual', True), |
| 300 | + ( |
| 301 | + master_doc, |
| 302 | + htmlhelp_basename + ".tex", |
| 303 | + "Sound Field Analysis toolbox Documentation", |
| 304 | + author, |
| 305 | + "manual", |
| 306 | + True, |
| 307 | + ), |
285 | 308 | ] |
286 | 309 |
|
| 310 | +# supported_image_types = ['application/pdf', 'image/png', 'image/jpeg'] |
| 311 | + |
287 | 312 | # The name of an image file (relative to this directory) to place at the top of |
288 | 313 | # the title page. |
289 | 314 | # |
|
322 | 347 | # One entry per manual page. List of tuples |
323 | 348 | # (source start file, name, description, authors, manual section). |
324 | 349 | man_pages = [ |
325 | | - (master_doc, 'sfa_readme', 'Sound Field Analysis Toolbox Readme', |
326 | | - [author], 1) |
| 350 | + ( |
| 351 | + master_doc, |
| 352 | + htmlhelp_basename, |
| 353 | + "Sound Field Analysis toolbox Documentation", |
| 354 | + [author], |
| 355 | + 1, |
| 356 | + ) |
327 | 357 | ] |
328 | 358 |
|
329 | 359 | # If true, show URL addresses after external links. |
|
337 | 367 | # (source start file, target name, title, author, |
338 | 368 | # dir menu entry, description, category) |
339 | 369 | texinfo_documents = [ |
340 | | - (master_doc, 'sfa_readme', 'Sound Field Analysis Toolbox for Python Readme', |
341 | | - author, 'sfa_readme', 'Analyze, visualize and process sound field data recorded by spherical microphone arrays.', |
342 | | - 'Miscellaneous'), |
| 370 | + ( |
| 371 | + master_doc, |
| 372 | + htmlhelp_basename, |
| 373 | + "Sound Field Analysis toolbox Documentation", |
| 374 | + author, |
| 375 | + htmlhelp_basename, |
| 376 | + "Analyze, visualize and process sound field data recorded by spherical microphone arrays.", |
| 377 | + "Miscellaneous", |
| 378 | + ), |
343 | 379 | ] |
344 | 380 |
|
345 | 381 | # Documents to append as an appendix to all manuals. |
|
0 commit comments