[708c667] | 1 | # -*- coding: utf-8 -*- |
---|
| 2 | # |
---|
| 3 | # Configuration file for the Sphinx documentation builder. |
---|
| 4 | # |
---|
| 5 | # This file does only contain a selection of the most common options. For a |
---|
| 6 | # full list see the documentation: |
---|
| 7 | # http://www.sphinx-doc.org/en/master/config |
---|
| 8 | |
---|
| 9 | # -- Path setup -------------------------------------------------------------- |
---|
| 10 | |
---|
| 11 | # If extensions (or modules to document with autodoc) are in another directory, |
---|
| 12 | # add these directories to sys.path here. If the directory is relative to the |
---|
| 13 | # documentation root, use os.path.abspath to make it absolute, like shown here. |
---|
| 14 | # |
---|
| 15 | import os |
---|
[0b00607] | 16 | import sys, glob |
---|
| 17 | sys.path.insert(0, os.path.abspath('../../../Source/Python')) |
---|
| 18 | sys.path.insert(0, os.path.abspath('../../../Source/Python/Mods')) |
---|
| 19 | sys.path.insert(0, os.path.abspath('../../../Source/Python/Classes')) |
---|
[708c667] | 20 | |
---|
[0b00607] | 21 | sys.path.insert(0, os.path.abspath('_static/python')) |
---|
[30f7911] | 22 | sys.setrecursionlimit(1500) |
---|
[708c667] | 23 | |
---|
[0b00607] | 24 | #fortran_src = [f for f in os.listdir('../../../source/fortran') if '.f90' in f or '.f' in f] |
---|
| 25 | #print(fortran_src) |
---|
[708c667] | 26 | |
---|
| 27 | # -- Project information ----------------------------------------------------- |
---|
| 28 | |
---|
| 29 | project = u'flex_extract' |
---|
[b1674ed] | 30 | copyright = u'2020, Anne Philipp and Leopold Haimberger' |
---|
[708c667] | 31 | author = u'Anne Philipp and Leopold Haimberger' |
---|
| 32 | |
---|
| 33 | # The short X.Y version |
---|
| 34 | version = u'7.1' |
---|
| 35 | # The full version, including alpha/beta/rc tags |
---|
| 36 | release = u'7.1 alpha' |
---|
| 37 | |
---|
| 38 | |
---|
| 39 | # -- General configuration --------------------------------------------------- |
---|
| 40 | |
---|
| 41 | # If your documentation needs a minimal Sphinx version, state it here. |
---|
| 42 | # |
---|
| 43 | # needs_sphinx = '1.0' |
---|
| 44 | |
---|
| 45 | # Add any Sphinx extension module names here, as strings. They can be |
---|
| 46 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom |
---|
| 47 | # ones. |
---|
| 48 | extensions = [ |
---|
| 49 | 'sphinx.ext.napoleon', |
---|
| 50 | 'sphinx.ext.autodoc', |
---|
| 51 | 'sphinx.ext.autosectionlabel', |
---|
| 52 | 'sphinx.ext.todo', |
---|
| 53 | 'sphinx.ext.coverage', |
---|
| 54 | 'sphinx.ext.mathjax', |
---|
| 55 | 'sphinx.ext.ifconfig', |
---|
| 56 | 'sphinx.ext.viewcode', |
---|
| 57 | 'sphinx.ext.githubpages', |
---|
[41c9dbc] | 58 | 'sphinx-jsonschema', |
---|
[0b00607] | 59 | 'sphinx.ext.intersphinx', |
---|
| 60 | 'hidden_code_block', |
---|
| 61 | 'sphinxcontrib.exceltable', |
---|
| 62 | 'sphinxcontrib.seqdiag', |
---|
| 63 | 'sphinxcontrib.blockdiag', |
---|
| 64 | 'sphinx.ext.todo', |
---|
| 65 | # 'sphinxfortran.fortran_autodoc', |
---|
| 66 | # 'sphinxfortran.fortran_domain' |
---|
[708c667] | 67 | ] |
---|
| 68 | |
---|
[0b00607] | 69 | |
---|
| 70 | # Fontpath for seqdiag (truetype font) |
---|
| 71 | seqdiag_fontpath = '/usr/share/fonts/dejavu/DejaVuSerif.ttf' |
---|
| 72 | |
---|
| 73 | # Fontpath for blockdiag (truetype font) |
---|
| 74 | blockdiag_fontpath = '/usr/share/fonts/dejavu/DejaVuSerif.ttf' |
---|
| 75 | |
---|
| 76 | |
---|
[708c667] | 77 | # Add any paths that contain templates here, relative to this directory. |
---|
| 78 | templates_path = ['_templates'] |
---|
| 79 | |
---|
| 80 | # The suffix(es) of source filenames. |
---|
| 81 | # You can specify multiple suffix as a list of string: |
---|
| 82 | # |
---|
| 83 | # source_suffix = ['.rst', '.md'] |
---|
| 84 | source_suffix = ['.rst', '.md', '.txt'] |
---|
| 85 | |
---|
| 86 | # The master toctree document. |
---|
| 87 | master_doc = 'index' |
---|
| 88 | |
---|
| 89 | # The language for content autogenerated by Sphinx. Refer to documentation |
---|
| 90 | # for a list of supported languages. |
---|
| 91 | # |
---|
| 92 | # This is also used if you do content translation via gettext catalogs. |
---|
| 93 | # Usually you set "language" from the command line for these cases. |
---|
| 94 | language = None |
---|
| 95 | |
---|
| 96 | # List of patterns, relative to source directory, that match files and |
---|
| 97 | # directories to ignore when looking for source files. |
---|
| 98 | # This pattern also affects html_static_path and html_extra_path . |
---|
| 99 | exclude_patterns = [] |
---|
| 100 | |
---|
| 101 | # The name of the Pygments (syntax highlighting) style to use. |
---|
| 102 | pygments_style = 'sphinx' |
---|
| 103 | |
---|
| 104 | |
---|
| 105 | # -- Options for HTML output ------------------------------------------------- |
---|
| 106 | |
---|
| 107 | # The theme to use for HTML and HTML Help pages. See the documentation for |
---|
| 108 | # a list of builtin themes. |
---|
| 109 | # |
---|
| 110 | html_theme = 'sphinx_rtd_theme' |
---|
| 111 | |
---|
| 112 | # Theme options are theme-specific and customize the look and feel of a theme |
---|
| 113 | # further. For a list of options available for each theme, see the |
---|
| 114 | # documentation. |
---|
| 115 | # |
---|
[41c9dbc] | 116 | html_theme_options = { |
---|
| 117 | 'display_version': True, |
---|
| 118 | 'titles_only': False, |
---|
| 119 | } |
---|
[708c667] | 120 | |
---|
| 121 | # Add any paths that contain custom static files (such as style sheets) here, |
---|
| 122 | # relative to this directory. They are copied after the builtin static files, |
---|
| 123 | # so a file named "default.css" will overwrite the builtin "default.css". |
---|
| 124 | html_static_path = ['_static'] |
---|
| 125 | |
---|
| 126 | # Custom sidebar templates, must be a dictionary that maps document names |
---|
| 127 | # to template names. |
---|
| 128 | # |
---|
| 129 | # The default sidebars (for documents that don't match any pattern) are |
---|
| 130 | # defined by theme itself. Builtin themes are using these templates by |
---|
| 131 | # default: ``['localtoc.html', 'relations.html', 'sourcelink.html', |
---|
| 132 | # 'searchbox.html']``. |
---|
| 133 | # |
---|
| 134 | # html_sidebars = {} |
---|
| 135 | |
---|
| 136 | |
---|
| 137 | # -- Options for HTMLHelp output --------------------------------------------- |
---|
| 138 | |
---|
| 139 | # Output file base name for HTML help builder. |
---|
| 140 | htmlhelp_basename = 'flex_extractdoc' |
---|
| 141 | |
---|
| 142 | |
---|
| 143 | # -- Options for LaTeX output ------------------------------------------------ |
---|
| 144 | |
---|
| 145 | latex_elements = { |
---|
| 146 | # The paper size ('letterpaper' or 'a4paper'). |
---|
| 147 | # |
---|
[41c9dbc] | 148 | 'papersize': 'a4paper', |
---|
[708c667] | 149 | |
---|
| 150 | # The font size ('10pt', '11pt' or '12pt'). |
---|
| 151 | # |
---|
[41c9dbc] | 152 | 'pointsize': '12pt', |
---|
[708c667] | 153 | |
---|
| 154 | # Additional stuff for the LaTeX preamble. |
---|
| 155 | # |
---|
| 156 | # 'preamble': '', |
---|
| 157 | |
---|
| 158 | # Latex figure (float) alignment |
---|
| 159 | # |
---|
[41c9dbc] | 160 | 'figure_align': 'htbp', |
---|
[708c667] | 161 | } |
---|
| 162 | |
---|
| 163 | # Grouping the document tree into LaTeX files. List of tuples |
---|
| 164 | # (source start file, target name, title, |
---|
| 165 | # author, documentclass [howto, manual, or own class]). |
---|
| 166 | latex_documents = [ |
---|
| 167 | (master_doc, 'flex_extract.tex', u'flex\\_extract Documentation', |
---|
| 168 | u'Anne Philipp and Leopold Haimberger', 'manual'), |
---|
| 169 | ] |
---|
| 170 | |
---|
| 171 | |
---|
| 172 | # -- Options for manual page output ------------------------------------------ |
---|
| 173 | |
---|
| 174 | # One entry per manual page. List of tuples |
---|
| 175 | # (source start file, name, description, authors, manual section). |
---|
| 176 | man_pages = [ |
---|
| 177 | (master_doc, 'flex_extract', u'flex_extract Documentation', |
---|
| 178 | [author], 1) |
---|
| 179 | ] |
---|
| 180 | |
---|
| 181 | |
---|
| 182 | # -- Options for Texinfo output ---------------------------------------------- |
---|
| 183 | |
---|
| 184 | # Grouping the document tree into Texinfo files. List of tuples |
---|
| 185 | # (source start file, target name, title, author, |
---|
| 186 | # dir menu entry, description, category) |
---|
| 187 | texinfo_documents = [ |
---|
| 188 | (master_doc, 'flex_extract', u'flex_extract Documentation', |
---|
| 189 | author, 'flex_extract', 'One line description of project.', |
---|
| 190 | 'Miscellaneous'), |
---|
| 191 | ] |
---|
| 192 | |
---|
| 193 | |
---|
| 194 | # -- Extension configuration ------------------------------------------------- |
---|
| 195 | |
---|
[41c9dbc] | 196 | html_context = { |
---|
| 197 | 'css_files': ['_static/css/custom.css', |
---|
| 198 | '_static/css/theme_overrides.css' |
---|
| 199 | ], |
---|
| 200 | } |
---|
| 201 | |
---|
[708c667] | 202 | # -- Options for todo extension ---------------------------------------------- |
---|
| 203 | |
---|
| 204 | # If true, `todo` and `todoList` produce output, else they produce nothing. |
---|
| 205 | todo_include_todos = True |
---|
[0b00607] | 206 | #todo_link_only = True |
---|
[41c9dbc] | 207 | |
---|
| 208 | |
---|
| 209 | # -- Add extra css ----------------------------------------------------------- |
---|
| 210 | def setup(app): |
---|
| 211 | app.add_stylesheet('css/custom.css') |
---|
| 212 | |
---|
| 213 | |
---|
| 214 | |
---|