179
|
1 |
{% extends "layout.html" %}
|
|
2 |
{% set title = _('Index') %}
|
|
3 |
{% block body %}
|
|
4 |
|
|
5 |
<h1 id="index">{{ _('Index') }}</h1>
|
|
6 |
|
|
7 |
{% for key, dummy in genindexentries -%}
|
|
8 |
<a href="#{{ key }}"><strong>{{ key }}</strong></a> {% if not loop.last %}| {% endif %}
|
|
9 |
{%- endfor %}
|
|
10 |
|
|
11 |
<hr />
|
|
12 |
|
|
13 |
{% for key, entries in genindexentries %}
|
|
14 |
<h2 id="{{ key }}">{{ key }}</h2>
|
|
15 |
<table width="100%" class="indextable"><tr><td width="33%" valign="top">
|
|
16 |
<dl>
|
|
17 |
{%- set breakat = genindexcounts[loop.index0] // 2 %}
|
|
18 |
{%- set numcols = 1 %}
|
|
19 |
{%- set numitems = 0 %}
|
|
20 |
{% for entryname, (links, subitems) in entries %}
|
|
21 |
<dt>{%- if links -%}<a href="{{ links[0] }}">{{ entryname|e }}</a>
|
|
22 |
{%- for link in links[1:] %}, <a href="{{ link }}">[{{ loop.index }}]</a>{% endfor -%}
|
|
23 |
{%- else -%}
|
|
24 |
{{ entryname|e }}
|
|
25 |
{%- endif -%}</dt>
|
|
26 |
{%- if subitems %}
|
|
27 |
<dd><dl>
|
|
28 |
{%- for subentryname, subentrylinks in subitems %}
|
|
29 |
<dt><a href="{{ subentrylinks[0] }}">{{ subentryname|e }}</a>
|
|
30 |
{%- for link in subentrylinks[1:] %}, <a href="{{ link }}">[{{ loop.index }}]</a>{% endfor -%}
|
|
31 |
</dt>
|
|
32 |
{%- endfor %}
|
|
33 |
</dl></dd>
|
|
34 |
{%- endif -%}
|
|
35 |
{%- set numitems = numitems + 1 + (subitems|length) -%}
|
|
36 |
{%- if numcols < 2 and numitems > breakat -%}
|
|
37 |
{%- set numcols = numcols+1 -%}
|
|
38 |
</dl></td><td width="33%" valign="top"><dl>
|
|
39 |
{%- endif -%}
|
|
40 |
{%- endfor %}
|
|
41 |
</dl></td></tr></table>
|
|
42 |
{% endfor %}
|
|
43 |
|
|
44 |
{% endblock %}
|
|
45 |
|
|
46 |
{% block sidebarrel %}
|
|
47 |
{% if split_index %}
|
|
48 |
<h4>{{ _('Index') }}</h4>
|
|
49 |
<p>{% for key, dummy in genindexentries -%}
|
|
50 |
<a href="{{ pathto('genindex-' + key) }}"><strong>{{ key }}</strong></a>
|
|
51 |
{% if not loop.last %}| {% endif %}
|
|
52 |
{%- endfor %}</p>
|
|
53 |
|
|
54 |
<p><a href="{{ pathto('genindex-all') }}"><strong>{{ _('Full index on one page') }}</strong></a></p>
|
|
55 |
{% endif %}
|
|
56 |
{{ super() }}
|
|
57 |
{% endblock %}
|