1 {# TEMPLATE VAR SETTINGS #}
2 {%- set url_root = pathto('', 1) %}
3 {%- if url_root == '#' %}{% set url_root = '' %}{% endif %}
4 {%- if not embedded and docstitle %}
5 {%- set titlesuffix = " — "|safe + docstitle|e %}
7 {%- set titlesuffix = "" %}
9 {%- set lang_attr = 'en' if language == None else (language | replace('_', '-')) %}
10 {%- set sphinx_writer = 'writer-html5' if html5_doctype else 'writer-html4' %}
13 <html class="{{ sphinx_writer }}" lang="{{ lang_attr }}" >
15 <meta charset="utf-8">
17 <meta name="viewport" content="width=device-width, initial-scale=1.0">
19 <title>{{ title|striptags|e }}{{ titlesuffix }}</title>
23 <link rel="stylesheet" href="{{ pathto('_static/' + style, 1) }}" type="text/css" />
24 <link rel="stylesheet" href="{{ pathto('_static/pygments.css', 1) }}" type="text/css" />
25 {%- for css in css_files %}
26 {%- if css|attr("rel") %}
27 <link rel="{{ css.rel }}" href="{{ pathto(css.filename, 1) }}" type="text/css"{% if css.title is not none %} title="{{ css.title }}"{% endif %} />
29 <link rel="stylesheet" href="{{ pathto(css, 1) }}" type="text/css" />
33 {%- for cssfile in extra_css_files %}
34 <link rel="stylesheet" href="{{ pathto(cssfile, 1) }}" type="text/css" />
39 <link rel="shortcut icon" href="{{ pathto('_static/' + favicon, 1) }}"/>
42 {% if theme_canonical_url %}
43 <link rel="canonical" href="{{ theme_canonical_url }}{{ pagename }}.html"/>
49 <script src="{{ pathto('_static/js/html5shiv.min.js', 1) }}"></script>
51 {%- if not embedded %}
52 {# XXX Sphinx 1.8.0 made this an external js-file, quick fix until we refactor the template to inherert more blocks directly from sphinx #}
53 {% if sphinx_version >= "1.8.0" %}
54 <script type="text/javascript" id="documentation_options" data-url_root="{{ pathto('', 1) }}" src="{{ pathto('_static/documentation_options.js', 1) }}"></script>
55 {%- for scriptfile in script_files %}
56 {{ js_tag(scriptfile) }}
59 <script type="text/javascript">
60 var DOCUMENTATION_OPTIONS = {
61 URL_ROOT:'{{ url_root }}',
62 VERSION:'{{ release|e }}',
63 LANGUAGE:'{{ language }}',
65 FILE_SUFFIX:'{{ '' if no_search_suffix else file_suffix }}',
66 HAS_SOURCE: {{ has_source|lower }},
67 SOURCELINK_SUFFIX: '{{ sourcelink_suffix }}'
70 {%- for scriptfile in script_files %}
71 <script type="text/javascript" src="{{ pathto(scriptfile, 1) }}"></script>
74 <script type="text/javascript" src="{{ pathto('_static/js/theme.js', 1) }}"></script>
77 {%- if use_opensearch %}
78 <link rel="search" type="application/opensearchdescription+xml"
79 title="{% trans docstitle=docstitle|e %}Search within {{ docstitle }}{% endtrans %}"
80 href="{{ pathto('_static/opensearch.xml', 1) }}"/>
86 {%- if hasdoc('about') %}
87 <link rel="author" title="{{ _('About these documents') }}" href="{{ pathto('about') }}" />
89 {%- if hasdoc('genindex') %}
90 <link rel="index" title="{{ _('Index') }}" href="{{ pathto('genindex') }}" />
92 {%- if hasdoc('search') %}
93 <link rel="search" title="{{ _('Search') }}" href="{{ pathto('search') }}" />
95 {%- if hasdoc('copyright') %}
96 <link rel="copyright" title="{{ _('Copyright') }}" href="{{ pathto('copyright') }}" />
99 <link rel="next" title="{{ next.title|striptags|e }}" href="{{ next.link|e }}" />
102 <link rel="prev" title="{{ prev.title|striptags|e }}" href="{{ prev.link|e }}" />
105 {%- block extrahead %} {% endblock %}
108 <body class="wy-body-for-nav">
110 {% block extrabody %} {% endblock %}
111 <div class="wy-grid-for-nav">
112 {# SIDE NAV, TOGGLES ON MOBILE #}
113 <nav data-toggle="wy-nav-shift" class="wy-nav-side">
114 <div class="wy-side-scroll">
115 <div class="wy-side-nav-search" {% if theme_style_nav_header_background %} style="background: {{theme_style_nav_header_background}}" {% endif %}>
116 {% block sidebartitle %}
118 {% if logo and theme_logo_only %}
119 <a href="{{ pathto(master_doc) }}">
121 <a href="{{ pathto(master_doc) }}" class="icon icon-home"> {{ project }}
125 {# Not strictly valid HTML, but it's the only way to display/scale
126 it properly, without weird scripting or heaps of work
128 <img src="{{ pathto('_static/' + logo, 1) }}" class="logo" alt="{{ _('Logo') }}"/>
132 {% if theme_display_version %}
133 {%- set nav_version = version %}
134 {% if READTHEDOCS and current_version %}
135 {%- set nav_version = current_version %}
138 <div class="version">
144 {% include "searchbox.html" %}
149 {% block navigation %}
150 <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
153 The singlehtml builder doesn't handle this toctree call when the
154 toctree is empty. Skip building this for now.
156 {% if 'singlehtml' not in builder %}
157 {% set global_toc = toctree(maxdepth=theme_navigation_depth|int,
158 collapse=theme_collapse_navigation|tobool,
159 includehidden=theme_includehidden|tobool,
160 titles_only=theme_titles_only|tobool) %}
166 <div class="local-toc">{{ toc }}</div>
174 <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
176 {# MOBILE NAV, TRIGGLES SIDE NAV ON TOGGLE #}
177 <nav class="wy-nav-top" aria-label="top navigation">
178 {% block mobile_nav %}
179 <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
180 <a href="{{ pathto(master_doc) }}">{{ project }}</a>
185 <div class="wy-nav-content">
187 {% if theme_style_external_links|tobool %}
188 <div class="rst-content style-external-links">
190 <div class="rst-content">
192 {% include "breadcrumbs.html" %}
193 <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article">
194 {%- block document %}
195 <div itemprop="articleBody">
196 {% block body %}{% endblock %}
198 {% if self.comments()|trim %}
199 <div class="articleComments">
200 {% block comments %}{% endblock %}
205 {% include "footer.html" %}
213 {% include "versions.html" %}
215 <script type="text/javascript">
217 SphinxRtdTheme.Navigation.enable({{ 'true' if theme_sticky_navigation|tobool else 'false' }});
221 {# Do not conflict with RTD insertion of analytics script #}
222 {% if not READTHEDOCS %}
223 {% if theme_analytics_id %}
224 <!-- Theme Analytics -->
226 (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
227 (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
228 m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
229 })(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
231 ga('create', '{{ theme_analytics_id }}', 'auto');
232 ga('send', 'pageview');
238 {%- block footer %} {% endblock %}