{%- block doctype -%}{%- if html5_doctype %} {%- else %} {%- endif %}{%- endblock %} {%- set url_root = pathto('', 1) %} {# XXX necessary? #} {%- if url_root == '#' %}{% set url_root = '' %}{% endif %} {%- macro css() %} {%- for css in css_files %} {%- if css|attr("rel") %} {%- else %} {%- endif %} {%- endfor %} {% if theme_canonical_url %} {% endif %} {%- endmacro %} {%- macro script() %} {# 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 #} {% if sphinx_version >= "1.8.0" %} {%- for scriptfile in script_files %} {{ js_tag(scriptfile) }} {%- endfor %} {% else %} {% include "documentation_options.html" %} {%- for scriptfile in script_files %} {%- endfor %} {% endif %} {%- endmacro %}