{% set theme_css_files = [] %} {% if theme_bootstrap_version == "3" %} {% set bootstrap_version, bootstrap_additional_css, navbar_version = "3.4.1", "theme", "" %} {% set bs_span_prefix = "col-md-" %} {% else %} {% set bootstrap_version, bootstrap_additional_css, navbar_version = "2.3.2", "responsive", "-2" %} {% set bs_span_prefix = "span" %} {% endif %} {% if theme_bootswatch_theme and theme_bootswatch_theme != "\"\"" %} {# BS2 needs "bootstrap-responsive.css". BS3 doesn't. #} {% if theme_bootstrap_version == "3" %} {% set theme_css_files = theme_css_files + [ '_static/bootswatch-' + bootstrap_version + '/' + theme_bootswatch_theme + '/bootstrap.min.css', '_static/bootstrap-sphinx.css' ] %} {% else %} {% set theme_css_files = theme_css_files + [ '_static/bootswatch-' + bootstrap_version + '/' + theme_bootswatch_theme + '/bootstrap.min.css', '_static/bootstrap-' + bootstrap_version + '/css/bootstrap-' + bootstrap_additional_css + '.min.css', '_static/bootstrap-sphinx.css' ] %} {% endif %} {% else %} {% set theme_css_files = theme_css_files + [ '_static/bootstrap-' + bootstrap_version + '/css/bootstrap.min.css', '_static/bootstrap-' + bootstrap_version + '/css/bootstrap-' + bootstrap_additional_css + '.min.css', '_static/bootstrap-sphinx.css' ] %} {% endif %} {% set bootswatch_css_custom = ['_static/extra.css?home=4'] %} {% set css_files = css_files + theme_css_files + bootswatch_css_custom %} {% set script_files = script_files + [ '_static/js/jquery-1.12.4.min.js', '_static/js/jquery-fix.js', '_static/bootstrap-' + bootstrap_version + '/js/bootstrap.js', '_static/bootstrap-sphinx.js' ] %} {%- set render_sidebar = (not embedded) and (not theme_nosidebar|tobool) and sidebars %} {%- set bs_content_width = render_sidebar and "9" or "12"%} {%- set website_titles = { 'index': _('SpeedCrunch — Free High-Precision Scientific Calculator'), 'download': _('Download SpeedCrunch for Windows, macOS and Linux'), 'community': _('SpeedCrunch Community and Support'), 'donate': _('Donate to Support SpeedCrunch') } %} {%- set website_descriptions = { 'index': _('SpeedCrunch is a free, open-source scientific calculator for Windows, macOS and Linux, with 50-digit precision, complex numbers and unit conversion.'), 'download': _('Download the free SpeedCrunch scientific calculator for Windows and macOS, find Linux installation options, and explore release notes and older versions.'), 'community': _('Connect with SpeedCrunch users, ask questions, share calculation tips, and follow news about this free, open-source scientific calculator.'), 'donate': _('Support SpeedCrunch development and hosting with a donation to keep this open-source scientific calculator free for everyone.') } %} {%- set seo_title = website_titles.get(pagename, (title|default('')|striptags) ~ ' — ' ~ _('SpeedCrunch Manual')) %} {%- if pageurl %} {# Use the site root rather than its duplicate index.html URL. #} {%- set canonical_url = pageurl[:-10] if pagename == 'index' else pageurl %} {%- endif %} {%- block doctype -%} {%- endblock %} {%- set reldelim1 = reldelim1 is not defined and ' »' or reldelim1 %} {%- set reldelim2 = reldelim2 is not defined and ' |' or reldelim2 %} {%- set render_sidebar = (not embedded) and (not theme_nosidebar|tobool) and (sidebars != []) %} {%- set url_root = pathto('', 1) %} {# XXX necessary? #} {%- if url_root == '#' %}{% set url_root = '' %}{% endif %} {%- if not embedded and docstitle %} {%- set titlesuffix = " — "|safe + docstitle|e %} {%- else %} {%- set titlesuffix = "" %} {%- endif %} {# Sidebar: Rework into our Bootstrap nav section. #} {% macro navBar() %} {% include "navbar" + navbar_version + ".html" %} {% endmacro %} {% if theme_bootstrap_version == "3" %} {%- macro bsidebar() %} {%- if render_sidebar %}