From c1f06a0b8745c2859c6f09789fd5965d87579c63 Mon Sep 17 00:00:00 2001 From: Jan Safranek Date: Wed, 2 Oct 2013 10:42:35 +0200 Subject: Add OpenLMI theme for Sphinx. Note that the theme is BSD-licensed. --- tools/openlmitheme/README | 3 + tools/openlmitheme/layout.html | 214 +++++++++++++++++++++++++++++ tools/openlmitheme/static/openlmi-logo.png | Bin 0 -> 6324 bytes tools/openlmitheme/static/openlmi.css | 66 +++++++++ tools/openlmitheme/theme.conf | 28 ++++ 5 files changed, 311 insertions(+) create mode 100644 tools/openlmitheme/README create mode 100644 tools/openlmitheme/layout.html create mode 100644 tools/openlmitheme/static/openlmi-logo.png create mode 100644 tools/openlmitheme/static/openlmi.css create mode 100644 tools/openlmitheme/theme.conf (limited to 'tools/openlmitheme') diff --git a/tools/openlmitheme/README b/tools/openlmitheme/README new file mode 100644 index 0000000..a17989b --- /dev/null +++ b/tools/openlmitheme/README @@ -0,0 +1,3 @@ +This is OpenLMI theme for Sphix. + +It's based on openlmi.org css. \ No newline at end of file diff --git a/tools/openlmitheme/layout.html b/tools/openlmitheme/layout.html new file mode 100644 index 0000000..92f7118 --- /dev/null +++ b/tools/openlmitheme/layout.html @@ -0,0 +1,214 @@ +{# + based on sphinx basic/layout.html + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + + :copyright: Copyright 2007-2011 by the Sphinx team, see Sphinx AUTHORS. + :license: BSD, see Sphinx LICENSE for details. + + Changes for OpenLMI: + - no 'relbar' on bottom + - 'relbar' includes project image and larger font, based on openlmi.org design. +#} +{%- 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 %} + +{%- macro relbar() %} + +{%- endmacro %} + +{%- macro sidebar() %} + {%- if render_sidebar %} +
+
+ {%- block sidebarlogo %} + {%- if logo %} + + {%- endif %} + {%- endblock %} + {%- if sidebars != None %} + {#- new style sidebar: explicitly include/exclude templates #} + {%- for sidebartemplate in sidebars %} + {%- include sidebartemplate %} + {%- endfor %} + {%- else %} + {#- old style sidebars: using blocks -- should be deprecated #} + {%- block sidebartoc %} + {%- include "localtoc.html" %} + {%- endblock %} + {%- block sidebarrel %} + {%- include "relations.html" %} + {%- endblock %} + {%- block sidebarsourcelink %} + {%- include "sourcelink.html" %} + {%- endblock %} + {%- if customsidebar %} + {%- include customsidebar %} + {%- endif %} + {%- block sidebarsearch %} + {%- include "searchbox.html" %} + {%- endblock %} + {%- endif %} +
+
+ {%- endif %} +{%- endmacro %} + +{%- macro script() %} + + {%- for scriptfile in script_files %} + + {%- endfor %} +{%- endmacro %} + +{%- macro css() %} + + + {%- for cssfile in css_files %} + + {%- endfor %} +{%- endmacro %} + + + + + {{ metatags }} + {%- block htmltitle %} + {{ title|striptags|e }}{{ titlesuffix }} + {%- endblock %} + {{ css() }} + {%- if not embedded %} + {{ script() }} + {%- if use_opensearch %} + + {%- endif %} + {%- if favicon %} + + {%- endif %} + {%- endif %} +{%- block linktags %} + {%- if hasdoc('about') %} + + {%- endif %} + {%- if hasdoc('genindex') %} + + {%- endif %} + {%- if hasdoc('search') %} + + {%- endif %} + {%- if hasdoc('copyright') %} + + {%- endif %} + + {%- if parents %} + + {%- endif %} + {%- if next %} + + {%- endif %} + {%- if prev %} + + {%- endif %} +{%- endblock %} +{%- block extrahead %} {% endblock %} + + +{%- block header %}{% endblock %} + +{%- block relbar1 %}{{ relbar() }}{% endblock %} + +{%- block content %} + {%- block sidebar1 %} {# possible location for sidebar #} {% endblock %} + +
+ {%- block document %} +
+ {%- if render_sidebar %} +
+ {%- endif %} +
+ {% block body %} {% endblock %} +
+ {%- if render_sidebar %} +
+ {%- endif %} +
+ {%- endblock %} + + {%- block sidebar2 %}{{ sidebar() }}{% endblock %} +
+
+{%- endblock %} + +{%- block footer %} + +{%- endblock %} + + diff --git a/tools/openlmitheme/static/openlmi-logo.png b/tools/openlmitheme/static/openlmi-logo.png new file mode 100644 index 0000000..e414797 Binary files /dev/null and b/tools/openlmitheme/static/openlmi-logo.png differ diff --git a/tools/openlmitheme/static/openlmi.css b/tools/openlmitheme/static/openlmi.css new file mode 100644 index 0000000..a61c777 --- /dev/null +++ b/tools/openlmitheme/static/openlmi.css @@ -0,0 +1,66 @@ +@import url("default.css"); + +p.caption { + font-size: 90%; + font-style: italic; +} + +h1 { + font-size: 2em; + line-height: 1; +} + +div.sphinxsidebar li li { + padding: 0.4em 0.1em 0 0; +} + +div.body { + font-size: 1.071em; +} + +div.related { + background-color: #48a9e4; + background-image: -moz-linear-gradient(top, #0779bf 0%, #48a9e4 100%); + background-image: -ms-linear-gradient(top, #0779bf 0%, #48a9e4 100%); + background-image: -o-linear-gradient(top, #0779bf 0%, #48a9e4 100%); + background-image: -webkit-gradient(linear, left top, left bottom, color-stop(0, #0779bf), color-stop(1, #48a9e4)); + background-image: -webkit-linear-gradient(top, #0779bf 0%, #48a9e4 100%); + background-image: linear-gradient(top, #0779bf 0%, #48a9e4 100%); + line-height: 15px; + padding-bottom: 10px; +} + +div.related ul { + font-weight:bold; +} +body { + font-size: 87%; +} + +img.logo { + padding: 15px 15px 15px 10px; +} + +div.logo { + float: left; +} + +div.header { + padding-top: 15px; + margin: 0 0 10px 15px; +} + +h1.header { + font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; +} + +div.sphinxsidebarwrapper { + padding: 15px 20px; + margin: 15px; + background-color: #f6f6f2; + word-wrap: break-word; /* don't overflow with large items like LMI_SoftwareInstallationServiceAffectsElement*/ +} + +div.sphinxsidebar ul { + margin: 10px 0px 10px 0px; +} \ No newline at end of file diff --git a/tools/openlmitheme/theme.conf b/tools/openlmitheme/theme.conf new file mode 100644 index 0000000..f9fcc3d --- /dev/null +++ b/tools/openlmitheme/theme.conf @@ -0,0 +1,28 @@ +[theme] +inherit = default +stylesheet = openlmi.css + +[options] +use_index = False +show_sourcelink = False +show_copyright = False + +footerbgcolor=#292929 +sidebarbgcolor=white +sidebartextcolor=#3b3b3b +sidebarlinkcolor=#0071B3 + +relbarbgcolor=#48a9e4 +relbartextcolor=white +relbarlinkcolor=white + +bgcolor=white +textcolor=#3b3b3b +linkcolor=#0071B3 +visitedlinkcolor=#0071B3 +headbgcolor=white +headtextcolor=#3b3b3b +headlinkcolor=#0071B3 + +bodyfont='Georgia, 'Times New Roman', Times, serif' +headfont='Georgia, 'Times New Roman', Times, serif' \ No newline at end of file -- cgit