Skip to content

Use the new scipy.org theme #2

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 6, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "scipy-sphinx-theme"]
path = scipy-sphinx-theme
url = https://github.com/scipy/scipy-sphinx-theme.git
7 changes: 7 additions & 0 deletions README.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
This repository contains the Sphinx source for the NumPy website
(http://www.numpy.org/).

After cloning this repository, run

$ git submodule init
$ git submodule update

To get the Sphinx theme used.

To make a local build of the website

$ make html
Expand Down
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
File renamed without changes
11 changes: 11 additions & 0 deletions _templates/layout.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{% extends "!layout.html" %}

{%- block header %}
<div class="container">
<div class="top-scipy-org-logo-header" style="background-color: #a2bae8;">
<a href="{{ pathto('index') }}">
<img border=0 alt="NumPy" src="{{ pathto('_static/numpy_logo.png', 1) }}"></a>
</div>
</div>
</div>
{% endblock %}
21 changes: 21 additions & 0 deletions _templates/sitenav.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{% block sitenav %}

<style>
a.extlink:after {
margin-left: 5px;
content: url("{{ pathto('_static/external-link.png', 1) }}");
}
</style>

<div class="well sidebar-nav">
<ul class="nav nav-list">
<li {% if pagename == 'index' -%}class="active"{%- endif -%}>
<a href="{{ pathto('index') }}">About Numpy</a></li>
<li {% if pagename == 'license' -%}class="active"{%- endif -%}>
<a href="{{ pathto('license') }}">License</a></li>
<li {% if pagename == 'old_array_packages' -%}class="active"{%- endif -%}>
<a href="{{ pathto('old_array_packages') }}">Old array packages</a></li>
</ul>
</div>

{% endblock %}
12 changes: 0 additions & 12 deletions _theme/scipy/layout.html

This file was deleted.

215 changes: 0 additions & 215 deletions _theme/scipy/static/scipy.css

This file was deleted.

4 changes: 0 additions & 4 deletions _theme/scipy/theme.conf

This file was deleted.

19 changes: 13 additions & 6 deletions conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@

# List of directories, relative to source directory, that shouldn't be searched
# for source files.
exclude_trees = []
exclude_trees = ['scipy-sphinx-theme']

# The reST default role (used for this markup: `text`) to use for all documents.
#default_role = None
Expand Down Expand Up @@ -97,10 +97,14 @@
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#html_theme_options = {}
html_theme_options = {
'sidebar': 'right',
'rootlinks': [("http://scipy.org/", "Scipy.org")],
'navigation_links': False,
}

# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = ["_theme"]
html_theme_path = ["scipy-sphinx-theme/_theme"]

# The name for this set of Sphinx documents. If None, it defaults to
# "<project> v<release> documentation".
Expand All @@ -117,12 +121,12 @@
# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
# pixels large.
#html_favicon = None
html_favicon = 'favicon.ico'
html_favicon = '_static/favicon.ico'

# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
#html_static_path = ['static']
html_static_path = ['_static']

# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
# using the given strftime format.
Expand All @@ -133,7 +137,10 @@
#html_use_smartypants = True

# Custom sidebar templates, maps document names to template names.
#html_sidebars = {}
html_sidebars = {
'**': ['sitenav.html', 'localtoc.html'],
'index': ['sitenav.html'],
}

# Additional templates that should be rendered to pages, maps page names to
# template names.
Expand Down
Loading