|
1 | 1 | # -*- coding: utf-8 -*-
|
2 | 2 |
|
3 |
| -# SPDX-FileCopyrightText: 2021 ladyada for Adafruit Industries |
| 3 | +# SPDX-FileCopyrightText: 2017 Scott Shawcroft, written for Adafruit Industries |
4 | 4 | #
|
5 | 5 | # SPDX-License-Identifier: MIT
|
6 | 6 |
|
|
19 | 19 | "sphinx.ext.autodoc",
|
20 | 20 | "sphinxcontrib.jquery",
|
21 | 21 | "sphinx.ext.intersphinx",
|
22 |
| - "sphinx.ext.viewcode", |
| 22 | + "sphinx.ext.napoleon", |
| 23 | + "sphinx.ext.todo", |
23 | 24 | ]
|
24 | 25 |
|
| 26 | +# TODO: Please Read! |
| 27 | +# Uncomment the below if you use native CircuitPython modules such as |
| 28 | +# digitalio, micropython and busio. List the modules you use. Without it, the |
| 29 | +# autodoc module docs will fail to generate with a warning. |
| 30 | +autodoc_mock_imports = ["usb_hid"] |
| 31 | + |
| 32 | +autodoc_preserve_defaults = True |
| 33 | + |
| 34 | + |
25 | 35 | intersphinx_mapping = {
|
26 | 36 | "python": ("https://docs.python.org/3", None),
|
27 | 37 | "CircuitPython": ("https://docs.circuitpython.org/en/latest/", None),
|
28 | 38 | }
|
29 | 39 |
|
| 40 | +# Show the docstring from both the class and its __init__() method. |
| 41 | +autoclass_content = "both" |
| 42 | + |
30 | 43 | # Add any paths that contain templates here, relative to this directory.
|
31 | 44 | templates_path = ["_templates"]
|
32 | 45 |
|
|
47 | 60 | copyright = year_duration + " Scott Shawcroft"
|
48 | 61 | author = "Scott Shawcroft"
|
49 | 62 |
|
50 |
| -# Ignore imports of these modules, which sphinx will not know about. |
51 |
| -autodoc_mock_imports = ["usb_hid"] |
52 |
| - |
53 | 63 | # The version info for the project you're documenting, acts as replacement for
|
54 | 64 | # |version| and |release|, also used in various other places throughout the
|
55 | 65 | # built documents.
|
|
69 | 79 | # List of patterns, relative to source directory, that match files and
|
70 | 80 | # directories to ignore when looking for source files.
|
71 | 81 | # This patterns also effect to html_static_path and html_extra_path
|
72 |
| -exclude_patterns = ["_build", "Thumbs.db", ".DS_Store", ".env", "CODE_OF_CONDUCT.md"] |
| 82 | +exclude_patterns = [ |
| 83 | + "_build", |
| 84 | + "Thumbs.db", |
| 85 | + ".DS_Store", |
| 86 | + ".env", |
| 87 | + "CODE_OF_CONDUCT.md", |
| 88 | +] |
73 | 89 |
|
74 | 90 | # The reST default role (used for this markup: `text`) to use for all
|
75 | 91 | # documents.
|
|
89 | 105 | # If this is True, todo emits a warning for each TODO entries. The default is False.
|
90 | 106 | todo_emit_warnings = True
|
91 | 107 |
|
| 108 | +napoleon_numpy_docstring = False |
92 | 109 |
|
93 | 110 | # -- Options for HTML output ----------------------------------------------
|
94 | 111 |
|
|
118 | 135 |
|
119 | 136 | latex_elements = {
|
120 | 137 | # The paper size ('letterpaper' or 'a4paper').
|
121 |
| - # |
122 | 138 | # 'papersize': 'letterpaper',
|
123 | 139 | # The font size ('10pt', '11pt' or '12pt').
|
124 |
| - # |
125 | 140 | # 'pointsize': '10pt',
|
126 | 141 | # Additional stuff for the LaTeX preamble.
|
127 |
| - # |
128 | 142 | # 'preamble': '',
|
129 | 143 | # Latex figure (float) alignment
|
130 |
| - # |
131 | 144 | # 'figure_align': 'htbp',
|
132 | 145 | }
|
133 | 146 |
|
|
0 commit comments