|
| 1 | +# Configuration file for the Sphinx documentation builder. |
| 2 | +# https://www.sphinx-doc.org/en/master/usage/configuration.html |
| 3 | + |
| 4 | +import os |
| 5 | +import sys |
| 6 | + |
| 7 | +# Add the project root to Python path |
| 8 | +sys.path.insert(0, os.path.abspath('../../src')) |
| 9 | + |
| 10 | +# -- Project information ----------------------------------------------------- |
| 11 | +project = 'unstructuredDataHandler' |
| 12 | +copyright = '2024, SoftwareDevLabs' |
| 13 | +author = 'SoftwareDevLabs' |
| 14 | +release = '1.0.0' |
| 15 | + |
| 16 | +# -- General configuration --------------------------------------------------- |
| 17 | +extensions = [ |
| 18 | + 'sphinx.ext.autodoc', |
| 19 | + 'sphinx.ext.viewcode', |
| 20 | + 'sphinx.ext.napoleon', |
| 21 | + 'sphinx.ext.intersphinx', |
| 22 | + 'sphinx.ext.graphviz', |
| 23 | + 'sphinx.ext.inheritance_diagram', |
| 24 | + 'sphinx_autodoc_typehints', |
| 25 | + 'sphinx_design', |
| 26 | + 'sphinx_copybutton', |
| 27 | + 'sphinx_tabs.tabs', |
| 28 | + 'sphinx_togglebutton', |
| 29 | + 'myst_parser', |
| 30 | +] |
| 31 | + |
| 32 | +templates_path = ['_templates'] |
| 33 | +exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', 'README.md'] |
| 34 | + |
| 35 | +# -- Options for HTML output ------------------------------------------------ |
| 36 | +html_theme = 'furo' |
| 37 | +html_static_path = ['_static'] |
| 38 | + |
| 39 | +# Furo theme configuration (only supported options) |
| 40 | +html_theme_options = { |
| 41 | + "sidebar_hide_name": False, |
| 42 | + "light_css_variables": { |
| 43 | + "color-brand-primary": "#2196F3", |
| 44 | + "color-brand-content": "#1976D2", |
| 45 | + }, |
| 46 | + "dark_css_variables": { |
| 47 | + "color-brand-primary": "#64B5F6", |
| 48 | + "color-brand-content": "#42A5F5", |
| 49 | + }, |
| 50 | +} |
| 51 | + |
| 52 | +# Add custom CSS |
| 53 | +html_css_files = [ |
| 54 | + 'custom.css', |
| 55 | +] |
| 56 | + |
| 57 | +# -- Extension configuration ------------------------------------------------ |
| 58 | + |
| 59 | +# Napoleon settings (for Google/NumPy docstring style) |
| 60 | +napoleon_google_docstring = True |
| 61 | +napoleon_numpy_docstring = True |
| 62 | +napoleon_include_init_with_doc = False |
| 63 | +napoleon_include_private_with_doc = False |
| 64 | +napoleon_include_special_with_doc = True |
| 65 | +napoleon_use_admonition_for_examples = False |
| 66 | +napoleon_use_admonition_for_notes = False |
| 67 | +napoleon_use_admonition_for_references = False |
| 68 | +napoleon_use_ivar = False |
| 69 | +napoleon_use_param = True |
| 70 | +napoleon_use_rtype = True |
| 71 | + |
| 72 | +# Autodoc settings |
| 73 | +autodoc_default_options = { |
| 74 | + 'members': True, |
| 75 | + 'member-order': 'bysource', |
| 76 | + 'special-members': '__init__', |
| 77 | + 'undoc-members': True, |
| 78 | + 'exclude-members': '__weakref__' |
| 79 | +} |
| 80 | + |
| 81 | +# Intersphinx mapping |
| 82 | +intersphinx_mapping = { |
| 83 | + 'python': ('https://docs.python.org/3/', None), |
| 84 | +} |
| 85 | + |
| 86 | +# Type hints configuration |
| 87 | +typehints_fully_qualified = False |
| 88 | +always_document_param_types = True |
| 89 | + |
| 90 | +# Enhanced copy button configuration |
| 91 | +copybutton_prompt_text = r">>> |\.\.\. |\$ |In \[\d*\]: | {2,5}\.\.\.: | {5,8}: " |
| 92 | +copybutton_prompt_is_regexp = True |
| 93 | +copybutton_selector = "div.highlight pre, div.highlight code" |
| 94 | + |
| 95 | +# Myst parser configuration |
| 96 | +myst_enable_extensions = [ |
| 97 | + "colon_fence", |
| 98 | + "deflist", |
| 99 | + "fieldlist", |
| 100 | + "html_admonition", |
| 101 | + "html_image", |
| 102 | + "replacements", |
| 103 | + "smartquotes", |
| 104 | + "strikethrough", |
| 105 | + "substitution", |
| 106 | + "tasklist", |
| 107 | +] |
| 108 | + |
| 109 | +# Graphviz configuration - simplified to avoid emoji font issues |
| 110 | +graphviz_output_format = 'png' |
| 111 | +graphviz_dot_args = ['-Gfontname=Arial', '-Nfontname=Arial', '-Efontname=Arial'] |
| 112 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 113 | + |
| 114 | +# Enhanced extensions for advanced documentation |
| 115 | +extensions.extend([ |
| 116 | + 'sphinx.ext.graphviz', |
| 117 | + 'sphinx.ext.inheritance_diagram', |
| 118 | + 'sphinx_design', |
| 119 | + 'sphinx_copybutton', |
| 120 | + 'sphinx_tabs.tabs', |
| 121 | + 'sphinx_togglebutton', |
| 122 | +]) |
| 123 | + |
| 124 | +# Graphviz configuration |
| 125 | +graphviz_output_format = 'png' |
| 126 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 127 | + |
| 128 | +# Enhanced HTML theme configuration |
| 129 | +html_theme_options = { |
| 130 | + 'navigation_depth': 4, |
| 131 | + 'collapse_navigation': False, |
| 132 | + 'sticky_navigation': True, |
| 133 | + 'includehidden': True, |
| 134 | + 'titles_only': False |
| 135 | +} |
| 136 | + |
| 137 | +# Add custom CSS |
| 138 | +html_static_path = ['_static'] |
| 139 | +html_css_files = [ |
| 140 | + 'custom.css', |
| 141 | +] |
| 142 | + |
| 143 | +# Enhanced extensions for advanced documentation |
| 144 | +extensions.extend([ |
| 145 | + 'sphinx.ext.graphviz', |
| 146 | + 'sphinx.ext.inheritance_diagram', |
| 147 | + 'sphinx_design', |
| 148 | + 'sphinx_copybutton', |
| 149 | + 'sphinx_tabs.tabs', |
| 150 | + 'sphinx_togglebutton', |
| 151 | +]) |
| 152 | + |
| 153 | +# Graphviz configuration |
| 154 | +graphviz_output_format = 'png' |
| 155 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 156 | + |
| 157 | +# Enhanced HTML theme configuration |
| 158 | +html_theme_options = { |
| 159 | + 'navigation_depth': 4, |
| 160 | + 'collapse_navigation': False, |
| 161 | + 'sticky_navigation': True, |
| 162 | + 'includehidden': True, |
| 163 | + 'titles_only': False |
| 164 | +} |
| 165 | + |
| 166 | +# Add custom CSS |
| 167 | +html_static_path = ['_static'] |
| 168 | +html_css_files = [ |
| 169 | + 'custom.css', |
| 170 | +] |
| 171 | + |
| 172 | +# Enhanced extensions for advanced documentation |
| 173 | +extensions.extend([ |
| 174 | + 'sphinx.ext.graphviz', |
| 175 | + 'sphinx.ext.inheritance_diagram', |
| 176 | + 'sphinx_design', |
| 177 | + 'sphinx_copybutton', |
| 178 | + 'sphinx_tabs.tabs', |
| 179 | + 'sphinx_togglebutton', |
| 180 | +]) |
| 181 | + |
| 182 | +# Graphviz configuration |
| 183 | +graphviz_output_format = 'png' |
| 184 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 185 | + |
| 186 | +# Enhanced HTML theme configuration |
| 187 | +html_theme_options = { |
| 188 | + 'navigation_depth': 4, |
| 189 | + 'collapse_navigation': False, |
| 190 | + 'sticky_navigation': True, |
| 191 | + 'includehidden': True, |
| 192 | + 'titles_only': False |
| 193 | +} |
| 194 | + |
| 195 | +# Add custom CSS |
| 196 | +html_static_path = ['_static'] |
| 197 | +html_css_files = [ |
| 198 | + 'custom.css', |
| 199 | +] |
| 200 | + |
| 201 | +# Enhanced extensions for advanced documentation |
| 202 | +extensions.extend([ |
| 203 | + 'sphinx.ext.graphviz', |
| 204 | + 'sphinx.ext.inheritance_diagram', |
| 205 | + 'sphinx_design', |
| 206 | + 'sphinx_copybutton', |
| 207 | + 'sphinx_tabs.tabs', |
| 208 | + 'sphinx_togglebutton', |
| 209 | +]) |
| 210 | + |
| 211 | +# Graphviz configuration |
| 212 | +graphviz_output_format = 'png' |
| 213 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 214 | + |
| 215 | +# Enhanced HTML theme configuration |
| 216 | +html_theme_options = { |
| 217 | + 'navigation_depth': 4, |
| 218 | + 'collapse_navigation': False, |
| 219 | + 'sticky_navigation': True, |
| 220 | + 'includehidden': True, |
| 221 | + 'titles_only': False |
| 222 | +} |
| 223 | + |
| 224 | +# Add custom CSS |
| 225 | +html_static_path = ['_static'] |
| 226 | +html_css_files = [ |
| 227 | + 'custom.css', |
| 228 | +] |
| 229 | + |
| 230 | +# Enhanced extensions for advanced documentation |
| 231 | +extensions.extend([ |
| 232 | + 'sphinx.ext.graphviz', |
| 233 | + 'sphinx.ext.inheritance_diagram', |
| 234 | + 'sphinx_design', |
| 235 | + 'sphinx_copybutton', |
| 236 | + 'sphinx_tabs.tabs', |
| 237 | + 'sphinx_togglebutton', |
| 238 | +]) |
| 239 | + |
| 240 | +# Graphviz configuration |
| 241 | +graphviz_output_format = 'png' |
| 242 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 243 | + |
| 244 | +# Enhanced HTML theme configuration |
| 245 | +html_theme_options = { |
| 246 | + 'navigation_depth': 4, |
| 247 | + 'collapse_navigation': False, |
| 248 | + 'sticky_navigation': True, |
| 249 | + 'includehidden': True, |
| 250 | + 'titles_only': False |
| 251 | +} |
| 252 | + |
| 253 | +# Add custom CSS |
| 254 | +html_static_path = ['_static'] |
| 255 | +html_css_files = [ |
| 256 | + 'custom.css', |
| 257 | +] |
| 258 | + |
| 259 | +# Enhanced extensions for advanced documentation |
| 260 | +extensions.extend([ |
| 261 | + 'sphinx.ext.graphviz', |
| 262 | + 'sphinx.ext.inheritance_diagram', |
| 263 | + 'sphinx_design', |
| 264 | + 'sphinx_copybutton', |
| 265 | + 'sphinx_tabs.tabs', |
| 266 | + 'sphinx_togglebutton', |
| 267 | +]) |
| 268 | + |
| 269 | +# Graphviz configuration |
| 270 | +graphviz_output_format = 'png' |
| 271 | +inheritance_graph_attrs = dict(rankdir="TB", size='"6.0, 8.0"', fontsize=14, ratio='compress') |
| 272 | + |
| 273 | +# Enhanced HTML theme configuration |
| 274 | +html_theme_options = { |
| 275 | + 'navigation_depth': 4, |
| 276 | + 'collapse_navigation': False, |
| 277 | + 'sticky_navigation': True, |
| 278 | + 'includehidden': True, |
| 279 | + 'titles_only': False |
| 280 | +} |
| 281 | + |
| 282 | +# Add custom CSS |
| 283 | +html_static_path = ['_static'] |
| 284 | +html_css_files = [ |
| 285 | + 'custom.css', |
| 286 | +] |
0 commit comments