Commit 3c37f3cb authored by Glenn Walbran's avatar Glenn Walbran

Use common build/theme from manual-build submodule

parent 07ce4e00
[submodule "localeimages"]
path = localeimages
url = https://git.mahara.org/user-manual/manual-images.git
[submodule "manual-build"]
path = manual-build
url = https://git.mahara.org/user-manual/manual-build.git
# Makefile for Sphinx documentation
# You can set these variables from the command line.
SPHINXOPTS =
SPHINXBUILD = sphinx-build
PAPER =
BUILDDIR = build
MAHARA =
TRANSLATIONS = en de fr nl
# TRANSLATIONS_UNSUPPORTED = ja
# TODO: Building Japanese language PDFs with LaTeX is non-trivial and poorly documented.
# TODO: Complicating it with Sphinx has made it pretty much impossible. Good luck!
# Internal variables.
PAPEROPT_a4 = -D latex_paper_size=a4
PAPEROPT_letter = -D latex_paper_size=letter
ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) source
.PHONY: help clean update html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo " html to make standalone HTML files"
@echo " dirhtml to make HTML files named index.html in directories"
@echo " singlehtml to make a single large HTML file"
@echo " pickle to make pickle files"
@echo " json to make JSON files"
@echo " htmlhelp to make HTML files and a HTML help project"
@echo " qthelp to make HTML files and a qthelp project"
@echo " devhelp to make HTML files and a Devhelp project"
@echo " epub to make an epub"
@echo " latex to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
@echo " latexpdf to make LaTeX files and run them through pdflatex"
@echo " text to make text files"
@echo " man to make manual pages"
@echo " changes to make an overview of all changed/added/deprecated items"
@echo " linkcheck to check all external links for integrity"
@echo " doctest to run all doctests embedded in the documentation (if enabled)"
clean:
-rm -rf $(BUILDDIR)/*
-rm -rf source/locales/*
# This is used by the build cronjob to checkout the correct manual version.
update:
git checkout .
git checkout $(MAHARA)_STABLE
git pull
fetchtranslations:
/bin/bash generate-mo-files.sh $(MAHARA)
preview:
$(SPHINXBUILD) -a -D language=en -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html/en/$(MAHARA)
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html/en/$(MAHARA)."
@echo "The 'LANG' tokens in the crosslinks block have not been replaced with 'en' however."
html: fetchtranslations
@$(foreach TRANSLATION,$(TRANSLATIONS), \
sed -i 's/LANG/$(TRANSLATION)/g' source/mahara/links.html; \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html/$(TRANSLATION)/$(MAHARA); \
git checkout source/mahara/links.html; \
echo "---------------"; \
)
@echo
@echo "Build finished. The HTML pages are in $(BUILDDIR)/html/<language>/$(MAHARA)."
dirhtml:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished. The dirhtml pages are in $(BUILDDIR)/dirhtml/<language>/$(MAHARA)."
singlehtml:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished. The singlehtml pages are in $(BUILDDIR)/singlehtml/<language>/$(MAHARA)."
pickle:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished. The pickle pages are in $(BUILDDIR)/pickle/<language>/$(MAHARA)."
json:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished. The json pages are in $(BUILDDIR)/json/<language>/$(MAHARA)."
htmlhelp:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished; now you can run HTML Help Workshop with the" \
".hhp project file in $(BUILDDIR)/htmlhelp/<language>/$(MAHARA)."
qthelp:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished; now you can run "qcollectiongenerator" with the" \
".qhcp project file in $(BUILDDIR)/qthelp/<language>/$(MAHARA), like this:"
@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/Mahara.qhcp"
@echo "To view the help file:"
@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/<language>/$(MAHARA)/Mahara.qhc"
devhelp:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished."
@echo "To view the help file:"
@echo "# mkdir -p $$HOME/.local/share/devhelp/Mahara"
@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/Mahara"
@echo "# devhelp"
epub: fetchtranslations
@$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub/$(TRANSLATION)/$(MAHARA); \
cp $(BUILDDIR)/epub/$(TRANSLATION)/$(MAHARA)/Mahara.epub $(BUILDDIR)/html/$(TRANSLATION)/$(MAHARA)/Mahara.epub; \
rm -r $(BUILDDIR)/epub/$(TRANSLATION)/$(MAHARA)/; \
echo "---------------"; \
)
@echo
@echo "Build finished. The epub files have been moved to $(BUILDDIR)/html/<language>/$(MAHARA)/Mahara.epub."
latex: fetchtranslations
@$(foreach TRANSLATION,$(TRANSLATIONS), \
echo "Translation [$(TRANSLATION)]..."; \
sphinxlang=$(TRANSLATION) $(SPHINXBUILD) -a -D language=$(TRANSLATION) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex/$(TRANSLATION)/$(MAHARA); \
echo "---------------"; \
)
@echo
@echo "Build finished. The latex pages are in $(BUILDDIR)/latex/<language>/$(MAHARA)."
@echo "Run \`make' in that directory to run these through (pdf)latex" \
"(use \`make latexpdf' here to do that automatically)."
latexpdf: latex
@$(foreach TRANSLATION,$(TRANSLATIONS), \
echo "Translation [$(TRANSLATION)]..."; \
sed -i s/,dvipdfmx// $(BUILDDIR)/latex/$(TRANSLATION)/$(MAHARA)/Mahara.tex; \
$(MAKE) PDFLATEX="xelatex -halt-on-error -file-line-error" -C $(BUILDDIR)/latex/$(TRANSLATION)/$(MAHARA) all-pdf|grep -P -A2 ":[0-9]+:\ .*|Error:"; \
cp $(BUILDDIR)/latex/$(TRANSLATION)/$(MAHARA)/Mahara.pdf $(BUILDDIR)/html/$(TRANSLATION)/$(MAHARA)/Mahara.pdf; \
echo "---------------"; \
)
@echo
@echo "Build finished. The PDF files are in $(BUILDDIR)/latex/<language>/$(MAHARA)."
@echo " NOTE: Japanese language PDF, if built, probably failed. This is expected for now."
text:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished. The text pages are in $(BUILDDIR)/text/<language>/$(MAHARA)."
man:
$(foreach TRANSLATION,$(TRANSLATIONS), \
$(SPHINXBUILD) -a -D language=$(TRANSLATION) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man/$(TRANSLATION)/$(MAHARA) \
;)
@echo
@echo "Build finished. The manual pages are in $(BUILDDIR)/man/<language>/$(MAHARA)."
changes:
$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
@echo
@echo "The overview file is in $(BUILDDIR)/changes."
linkcheck:
$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
@echo
@echo "Link check complete; look for any errors in the above output " \
"or in $(BUILDDIR)/linkcheck/output.txt."
doctest:
$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
@echo "Testing of doctests in the sources finished, look at the " \
"results in $(BUILDDIR)/doctest/output.txt."
manual-build/Makefile
\ No newline at end of file
The Mahara User Manual is written using [reStructuredText](http://docutils.sourceforge.net/rst.html)
and built using [Sphinx](http://www.sphinx-doc.org/).
Getting Started
===============
The Mahara manual build files are now located in a git submodule. This is to allow
the manuals for each version to be built in the same way with the same theme.
Contributing to and building the documentation
==============================================
To initialize the submodule run:
To get started, use a Python virtual environment to install the stuff in `requirements.txt`.
You'll also need a fairly recent distribution of TeX Live in order to render PDFs properly.
Ubuntu 16.04 ships with TeX Live 2015 which includes XeTeX, which handles Unicode and
OpenType fonts properly, and the language metrics (hyphenation etc.) that Sphinx uses to
build translations.
./bootstrap.sh
apt-get install python-virtualenv texlive-xetex texlive-lang-all texlive-fonts-extra
This will setup the submodule to the latest version. This script can be called at
any time to ensure the manual-build submodule is up to date.
Clone this git repository, and in its directory, start the environemnt and install the
requirements:
For advice on setting up your Sphinx environment refer to:
virtualenv venv
. venv/bin/activate
pip install -r requirements.txt
Then you can build the documentation with the make command:
make html latexpdf
Have a look at the
[Hitchhiker's Guide to Python](http://docs.python-guide.org/en/latest/dev/virtualenvs/)
tutorial for more information about how to use Python virtual environments; Don't panic,
it's easy!
Deploying to a server that can't install remote packages
========================================================
To do this, make a wheelhouse (a directory of pre-compiled Python packages) and copy it over
to your server, then on the server tell pip (in the virtual environment) to install them.
For instance, on your workstation:
pip wheel -w /tmp/wheelhouse -r requirements.txt
rsync -avz /tmp/wheelhouse my.server.com:/tmp/
And on the server:
cd /wherever/your/manual/is/installed
. venv/bin/activate
pip install --no-index --find-links=/tmp/wheelhouse
manual-build/README.md
#!/bin/bash
# Bootstrap must be run initially to fetch the mahara-build submodule which
# contains the build part of the manual.
#
# This command should be run periodically to ensure that your local copy of
# the submodule is the latest, which is what the build system at Mahara will
# likely be using.
#
git submodule update --init --remote manual-build
#!/bin/bash
types=(jpg jpeg gif png);
for image in `find source/images -type f -exec echo "{}" \;`; do
if [[ ${types[@]} =~ ${image#*.} ]]
then
convert $image -strip $image
convert $image -density 110 -units PixelsPerInch $image
fi
done
manual-build/convert_images_dpi.sh
\ No newline at end of file
#!/bin/bash
dir=$(dirname $0)
cd $dir
if ! which git >/dev/null; then
echo "Please install git before continuing."
exit 1
fi
if [ -z $1 ]; then
branch=$(git symbolic-ref HEAD|sed "s/refs\/heads\///")
echo "Mahara version not specified; determining from user-manual git branch: $branch"
version=$(echo $branch|sed "s/_.*//")
# Could do with a better test here, but for now this works:
if [ ! "$(echo $version|grep ^1)" = "$version" ]; then
echo "Failed to find a version."
exit 1
fi
echo "Obtained version: $version"
else
version=$1
fi
if which bzr >/dev/null; then
echo "Starting import of translations..."
else
echo "Please install bzr before continuing."
exit 1
fi
if [ ! -d launchpad ]; then
echo "Checking out the launchpad .po files"
bzr checkout lp:~mahara-lang/mahara-manual/${version}_STABLE-export launchpad || exit 1
elif [ -z $(find launchpad/.bzr/checkout/lock -type d -mmin 120 |head -1) ]; then
# Re-fetch from Launchpad if more than eight hours old, so that it
# skips during a dev or testing session, but a daily cron always fetches.
echo "Updating .po collection from launchpad"
cd launchpad
bzr switch --force ${version}_STABLE-export
cd ..
fi
#echo "Cleaning up from last time"
#rm -r source/locales # msgfmt will do merging otherwise
if [ $(ls launchpad/potfiles/ -1A | wc -l) -gt 0 ]; then
for dir in launchpad/potfiles/*; do
echo "Creating $dir .mo files"
for file in $dir/*; do
mofile="$(basename $file | sed s%.po$%%)/LC_MESSAGES$(echo $dir | sed s%launchpad/potfiles%%).mo"
mkdir -p "source/locales/$(basename $file | sed s%.po$%%)/LC_MESSAGES"
msgfmt "$dir/$(basename $file)" -o "source/locales/$mofile"
done
done
fi
#We always exit with success so that failing to fetch translations does not prevent
#the english(default) doc build
exit 0
manual-build/generate-mo-files.sh
\ No newline at end of file
#!/bin/bash
if which git >/dev/null; then
echo "Starting import of localised images..."
else
echo "Please install git before continuing."
exit
fi
echo "Updating the image submodule"
git submodule init
git submodule update
echo "Updating image collection from git.mahara.org"
cd localeimages
git checkout $1_STABLE
git pull
cd ..
Subproject commit 570a360500d2c4663253f52b8aa6005040a893f6
Subproject commit 1857fd2d1c4541627c688aecb3405618337fe886
diff -Naur ca-orig/Mahara.tex ca/Mahara.tex
--- ca-orig/Mahara.tex 2012-05-17 11:13:36.410066165 +1200
+++ ca/Mahara.tex 2012-05-17 09:57:09.097775354 +1200
@@ -1,6 +1,6 @@
% Generated by Sphinx.
\def\sphinxdocclass{report}
-\documentclass[a4paper,10pt,catalan]{sphinxmanual}
+\documentclass[a4paper,10pt]{sphinxmanual}
\usepackage[T1]{fontenc}
\usepackage[frenchb]{babel}
--- fr-orig/Mahara.tex 2012-08-09 22:49:55.069056963 +1200
+++ fr/Mahara.tex 2012-08-09 22:48:55.060954112 +1200
@@ -4,7 +4,7 @@
\DeclareUnicodeCharacter{00A0}{\nobreakspace}
\usepackage[T1]{fontenc}
-\usepackage[frenchb]{babel}
+\usepackage[ngerman]{babel}
\usepackage{times}
\usepackage[Sonny]{fncychap}
\usepackage{longtable}
--- fr-orig/Mahara.tex 2012-08-09 22:49:55.069056963 +1200
+++ fr/Mahara.tex 2012-08-09 22:48:55.060954112 +1200
@@ -4,7 +4,7 @@
\DeclareUnicodeCharacter{00A0}{\nobreakspace}
\usepackage[T1]{fontenc}
-\usepackage[frenchb]{babel}
+\usepackage[english]{babel}
\usepackage{times}
\usepackage[Sonny]{fncychap}
\usepackage{longtable}
diff -Naur fr-orig/Mahara.tex fr/Mahara.tex
--- fr-orig/Mahara.tex 2012-05-16 23:43:36.695386258 +1200
+++ fr/Mahara.tex 2012-05-16 23:48:42.751777010 +1200
@@ -17,7 +17,7 @@
\usepackage{verbatim}
\usepackage{url}
\usepackage{fontspec}
-\setmainfont{FreeSerif}
+\setmainfont{gargi}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{xunicode}
diff -Naur fr-orig/Mahara.tex fr/Mahara.tex
--- fr-orig/Mahara.tex 2012-05-16 23:43:36.695386258 +1200
+++ fr/Mahara.tex 2012-05-16 23:48:42.751777010 +1200
@@ -17,7 +17,7 @@
\usepackage{verbatim}
\usepackage{url}
\usepackage{fontspec}
-\setmainfont{FreeSerif}
+\setmainfont{WenQuanYi Micro Hei}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{xunicode}
diff -Naur fr-orig/Mahara.tex fr/Mahara.tex
--- fr-orig/Mahara.tex 2012-05-16 23:43:36.695386258 +1200
+++ fr/Mahara.tex 2012-05-16 23:48:42.751777010 +1200
@@ -17,7 +17,7 @@
\usepackage{verbatim}
\usepackage{url}
\usepackage{fontspec}
-\setmainfont{FreeSerif}
+\setmainfont{WenQuanYi Micro Hei}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{xunicode}
diff -Naur fr-orig/Makefile fr/Makefile
--- fr-orig/Makefile 2012-04-24 14:18:46.187054000 +1200
+++ fr/Makefile 2012-05-16 19:12:22.110884868 +1200
@@ -17,13 +17,13 @@
all-pdf-ja:
for f in *.pdf *.png *.gif *.jpg *.jpeg; do extractbb $$f; done
- for f in *.tex; do platex -kanji=utf8 $(LATEXOPTS) $$f; done
- for f in *.tex; do platex -kanji=utf8 $(LATEXOPTS) $$f; done
- for f in *.tex; do platex -kanji=utf8 $(LATEXOPTS) $$f; done
- -for f in *.idx; do mendex -U -f -d "`basename $$f .idx`.dic" -s python.ist $$f; done
- for f in *.tex; do platex -kanji=utf8 $(LATEXOPTS) $$f; done
- for f in *.tex; do platex -kanji=utf8 $(LATEXOPTS) $$f; done
- for f in *.dvi; do dvipdfmx $$f; done
+ for f in *.tex; do xelatex --no-pdf $(LATEXOPTS) $$f; done
+ for f in *.tex; do xelatex --no-pdf $(LATEXOPTS) $$f; done
+ for f in *.tex; do xelatex --no-pdf $(LATEXOPTS) $$f; done
+ -for f in *.idx; do mendex -g -f -d "`basename $$f .idx`.dic" -s python.ist $$f; done
+ for f in *.tex; do xelatex --no-pdf $(LATEXOPTS) $$f; done
+ for f in *.tex; do xelatex --no-pdf $(LATEXOPTS) $$f; done
+ for f in *.xdv; do xdvipdfmx $$f; done
zip: all-$(FMT)
mkdir $(ARCHIVEPREFIX)docs-$(FMT)
diff -Naur fr-orig/sphinx.sty fr/sphinx.sty
--- fr-orig/sphinx.sty 2012-04-24 14:18:46.187054000 +1200
+++ fr/sphinx.sty 2012-05-16 19:12:22.110884868 +1200
@@ -98,7 +98,7 @@
\pagenumbering{roman} % ToC & chapters
% Use this to set the font family for headers and other decor:
-\newcommand{\py@HeaderFamily}{\sffamily\bfseries}
+\newcommand{\py@HeaderFamily}{\bfseries}
% Redefine the 'normal' header/footer style when using "fancyhdr" package:
\@ifundefined{fancyhf}{}{
--- fr-orig/Mahara.tex 2012-08-09 22:49:55.069056963 +1200
+++ fr/Mahara.tex 2012-08-09 22:48:55.060954112 +1200
@@ -4,7 +4,7 @@
\DeclareUnicodeCharacter{00A0}{\nobreakspace}
\usepackage[T1]{fontenc}
-\usepackage[frenchb]{babel}
+\usepackage[dutch]{babel}
\usepackage{times}
\usepackage[Sonny]{fncychap}
\usepackage{longtable}
diff -Naur fr-orig/Mahara.tex fr/Mahara.tex
--- fr-orig/Mahara.tex 2012-05-16 19:07:20.230404958 +1200
+++ fr/Mahara.tex 2012-05-16 19:12:40.470916109 +1200
@@ -2,7 +2,6 @@
\def\sphinxdocclass{report}
\documentclass[a4paper,10pt,english]{sphinxmanual}
-\DeclareUnicodeCharacter{00A0}{\nobreakspace}
\usepackage{cmap}
\usepackage[T1]{fontenc}
\usepackage[frenchb]{babel}
\usepackage{times}
diff -Naur fr-orig/Mahara.tex fr/Mahara.tex
--- fr-orig/Mahara.tex 2012-05-16 23:43:36.695386258 +1200
+++ fr/Mahara.tex 2012-05-16 23:48:42.751777010 +1200
@@ -17,7 +17,7 @@
\usepackage{verbatim}
\usepackage{url}
\usepackage{fontspec}
-\setmainfont{FreeSerif}
+\setmainfont{WenQuanYi Micro Hei}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{xunicode}
diff -Naur fr-orig/Mahara.tex fr/Mahara.tex
--- fr-orig/Mahara.tex 2012-05-16 23:43:36.695386258 +1200
+++ fr/Mahara.tex 2012-05-16 23:48:42.751777010 +1200
@@ -17,7 +17,7 @@
\usepackage{verbatim}
\usepackage{url}
\usepackage{fontspec}
-\setmainfont{FreeSerif}
+\setmainfont{WenQuanYi Micro Hei}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{xunicode}
../manual-build/source/conf-common.py
\ No newline at end of file
This diff is collapsed.
../manual-build/source/mahara
\ No newline at end of file
Readme
=========
The responsive theme for the Mahara user manual is based on the
Basicstrap style theme for Sphinx
https://pythonhosted.org/sphinxjp.themes.basicstrap/
{% extends "basicstrap/layout.html" %}
{%- block extrahead %}
<!--[if lte IE 6]>
<link rel="stylesheet" href="{{ pathto('_static/ie6.css', 1) }}" type="text/css" media="screen" charset="utf-8" />
<![endif]-->
{%- if theme_favicon %}
<link rel="shortcut icon" href="{{ pathto('_static/'+theme_favicon, 1) }}"/>
{%- endif %}
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css">
<!-- Piwik -->
<script type="text/javascript">
var _paq = _paq || [];
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="//www.catalyst-analytics.nz/";
_paq.push(['setTrackerUrl', u+'piwik.php']);
_paq.push(['setSiteId', 5]);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s);
})();
</script>
<noscript><p><img src="//www.catalyst-analytics.nz/piwik.php?idsite=5" style="border:0;" alt="" /></p></noscript>
<!-- End Piwik Code -->
{% endblock %}
{%- macro relbar() %}
<div id="navbar-related" class=" related navbar {% if (theme_relbar_inverse|tobool) %}navbar-inverse{% else %}navbar-default{% endif %}" role="navigation" aria-label="related navigation">
<div class="navbar-inner">
<ul class="nav navbar-nav {% if theme_noresponsiverelbar|tobool %}text-center{% endif %}">
<li><a href="{{ pathto(master_doc) }}">{{ shorttitle|e }}</a></li>
</ul>
<ul class="nav navbar-nav {% if not theme_noresponsiverelbar|tobool %}pull-right hidden-{{ class_device_xs }} hidden-{{ class_device_sm }}{% else %}text-center{% endif %}">
{% if not (theme_nosidebar|tobool) %}
{%- for rellink in rellinks|reverse %}
<li><a href="{{ pathto(rellink[0]) }}" title="{{ rellink[1]|striptags|e }}" {{ accesskey(rellink[2]) }}>{{ rellink[3] }}</a></li>
{%- endfor %}
{%- block rootrellink %}
{%- endblock %}
{%- for parent in parents %}
<li><a href="{{ parent.link|e }}" {% if loop.last %}{{ accesskey("U") }}{% endif %}>{{ parent.title }}</a></li>
{%- endfor %}
<li><a href="#">top</a></li>
{%- block relbaritems %} {% endblock %}
{% else %}
{%- if prev %}
<li><a href="{{ prev.link|e }}"><i class="icon icon-double-angle-left"></i>&nbsp;{{ prev.title }}</a></li>
{%- endif %}
<li><a class="uplink" href="{{ pathto(master_doc) }}">{{ _('Contents') }}</a></li>
{%- if next %}
<li><a href="{{ next.link|e }}">{{ next.title }}&nbsp;<i class="icon icon-double-angle-right"></i></a></li>
{%- endif %}
<li><a href="#">top</a></li>
{%- endif %}
</ul>
</div>
</div>
{%- endmacro %}
{%- block sidebarlogo %}{%- endblock %}
{%- block sidebarsourcelink %}{%- endblock %}
{%- block footer %}
<div class="footer">
{%- if show_copyright %}
{%- if hasdoc('copyright') %}
{% trans path=pathto('copyright'), copyright=copyright|e %}The Mahara manual is licensed under your choice of <a href="http://creativecommons.org/licenses/by-sa/3.0/">Creative Commons Attribution-ShareAlike 3.0 unported</a> or <a href="http://www.gnu.org/licenses/gpl.html">GNU General Public License version 3 or later</a>{{ copyright }}.{% endtrans %}
{%- else %}
{% trans copyright=copyright|e %}The Mahara manual is licensed under your choice of <a href="http://creativecommons.org/licenses/by-sa/3.0/">Creative Commons Attribution-ShareAlike 3.0 unported</a> or <a href="http://www.gnu.org/licenses/gpl.html">GNU General Public License version 3 or later</a> {{ copyright }}.{% endtrans %}
{%- endif %}
{%- endif %}
{%- if last_updated %}
{% trans last_updated=last_updated|e %}Last updated on {{ last_updated }}.{% endtrans %}
{%- endif %}
{%- if show_sphinx %}
{% trans sphinx_version=sphinx_version|e %}Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> {{ sphinx_version }}.{% endtrans %}
{%- endif %}
</div>
{%- endblock %}
{% block crosslinks %}
<div class="crosslinks">
<h3>Links</h3>
<ul class="square">
<li><b><a href="http://manual.mahara.org/LANG/17.04/index.html">Mahara 17.04 user manual</a></b></li>
<li><a href="http://manual.mahara.org/LANG/16.10/index.html">Mahara 16.10 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/16.04/index.html">Mahara 16.04 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/15.10/index.html">Mahara 15.10 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/15.10/Mahara.epub">Mahara 15.10 user manual Epub</a></li>
<li><a href="http://manual.mahara.org/LANG/15.04/index.html">Mahara 15.04 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.10/index.html">Mahara 1.10 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.9/index.html">Mahara 1.9 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.8/index.html">Mahara 1.8 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.7/index.html">Mahara 1.7 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.6/index.html">Mahara 1.6 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.5/index.html">Mahara 1.5 user manual</a></li>
<li><a href="http://manual.mahara.org/LANG/1.4/index.html">Mahara 1.4 user manual</a></li>
</ul>
</div>
{% endblock %}
{#
basic/searchbox.html
~~~~~~~~~~~~~~~~~~~~
Sphinx sidebar template: quick search box.
:copyright: Copyright 2007-2010 by the Sphinx team, see AUTHORS.
:license: BSD, see LICENSE for details.
Kristina Hoeppner: Took out the reference to functions and modules in "Enter search terms."
#}
{%- if pagename != "search" %}
<div id="searchbox" style="display: none">
<h3>{{ _('Quick search') }}</h3>
<form class="search" action="{{ pathto('search') }}" method="get">
<label for="search">Enter search terms</label>
<input id="search" type="text" name="q" size="18" />
<button type="submit" value="{{ _('Go') }}">
<span class="fa fa-search"></span>
</button>
<input type="hidden" name="check_keywords" value="yes" />
<input type="hidden" name="area" value="default" />
</form>
<p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
{%- endif %}