Skip to content
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

WIP: doc style tweaks #2123

Closed
wants to merge 14 commits into from
1 change: 0 additions & 1 deletion doc/.gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
_build/
_themes/julia/static/jquery.js
26 changes: 6 additions & 20 deletions doc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,7 @@ ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
# the i18n builder cannot share the environment and doctrees with the others
I18NSPHINXOPTS = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .

JQUERYDEST = _themes/julia/static/jquery.js
JQUERYURL = http://code.jquery.com/jquery-latest.js
WGET = $(abspath ../deps)/jldownload

.PHONY: help clean clean-jquery cleanall get-jquery html dirhtml singlehtml pickle json htmlhelp qthelp devhelp \
.PHONY: help clean cleanall html dirhtml singlehtml pickle json htmlhelp qthelp devhelp \
epub latex latexpdf text man changes linkcheck doctest gettext listpkg

help:
Expand Down Expand Up @@ -50,27 +46,17 @@ clean:
-rm -rf $(BUILDDIR)/*
-rm -f sphinx/*.pyc

clean-jquery:
-rm -f $(JQUERYDEST)

cleanall: clean clean-jquery

get-jquery: $(JQUERYDEST)

$(JQUERYDEST):
$(WGET) $@ $(JQUERYURL)

html: get-jquery
html:
$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."

dirhtml: get-jquery
dirhtml:
$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."

singlehtml: get-jquery
singlehtml:
$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
@echo
@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
Expand All @@ -85,13 +71,13 @@ json:
@echo
@echo "Build finished; now you can process the JSON files."

htmlhelp: get-jquery
htmlhelp:
$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
@echo
@echo "Build finished; now you can run HTML Help Workshop with the" \
".hhp project file in $(BUILDDIR)/htmlhelp."

qthelp: get-jquery
qthelp:
$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
Expand Down
10 changes: 10 additions & 0 deletions doc/_templates/sidebarintro.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<p class="logo">
<img alt="Julia" src="http://d1qchgnwtps1zh.cloudfront.net/julia_logo.png">
</p>

<h3>Other formats</h3>
<ul>
<li><a href="http://media.readthedocs.org/pdf/julia/latest/julia.pdf">as PDF</a></li>
<li><a href="http://media.readthedocs.org/pdf/julia/latest/julia.epub">as ePub</a></li>
<li><a href="http://media.readthedocs.org/pdf/julia/latest/julia.zip">as zipped HTML</a></li>
</ul>
43 changes: 4 additions & 39 deletions doc/_themes/julia/layout.html
Original file line number Diff line number Diff line change
@@ -1,47 +1,12 @@
{% extends "basic/layout.html" %}
{% set reldelim1 = '&nbsp;/&nbsp;' %}

{# Silence the relbar's #}
{% block relbar1 %}{% endblock %}
{% block relbar2 %}{% endblock %}

{% set script_files = script_files + ['_static/sidebar.js'] %}
{%- block sidebar2 %}
{%- if render_sidebar %}
<div class="sphinxsidebar">
<div class="sphinxsidebarview">
<div class="sphinxsidebarwrapper">
<div class="sphinxsidebarbutton">
<div id="sidebarbutton">
<span>&laquo;</span>
</div>
</div>
<div class="sphinxsidebarcontentwrapper">
<div class="sphinxsidebarcontent">
{#- new style sidebar: explicitly include/exclude templates #}
{%- for sidebartemplate in sidebars %}
{%- include sidebartemplate %}
{%- endfor %}
</div>
</div>
</div>
</div>
</div>
{%- endif %}
{% endblock %}

{% block header %}
<div class="header">
<div class="title">Julia Documentation</div>
<div class="links">
<p> <a href="http://julialang.org/">julia</a>
| <a href="https://github.com/JuliaLang/julia">source</a>
| <a href="http://groups.google.com/group/julia-dev/">dev list</a>
| <a href="http://docs.julialang.org/en/latest/">docs</a>
| <a href="http://julialang.org/blog/">blog</a>
| <a href="http://feeds.feedburner.com/JuliaLang">rss</a>
</p>
</div>
</div>
{% block rootrellink %}
<li><a href="http://julialang.org/">Julia</a>{{ reldelim1 }}</li>
<li><a href="{{ pathto('index') }}">Documentation</a>{{ reldelim1 }}</li>
{% endblock %}

{% block footer %}
Expand Down
3 changes: 3 additions & 0 deletions doc/_themes/julia/localtoc.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@
:copyright: Copyright 2007-2011 by the Sphinx team, see AUTHORS.
:license: BSD, see LICENSE for details.
#}
<p class="logo">
<img alt="Julia" src="http://d1qchgnwtps1zh.cloudfront.net/julia_logo.png">
</p>
{%- if display_toc %}
<h3><a href="{{ pathto(master_doc) }}">{{ _('Table Of Contents') }}</a></h3>
{{ toc }}
Expand Down
Loading