8000 DOC: re-arrange contents.rst and top navbar · matplotlib/matplotlib@3e6aff1 · GitHub
[go: up one dir, main page]

Skip to content

Commit 3e6aff1

Browse files
committed
DOC: re-arrange contents.rst and top navbar
This hard codes the contents of the top bar which gets us out of the trap that we want to have a different top-level structure to our complete documentation than we want to have in the nav bar.
1 parent 3bae524 commit 3e6aff1

File tree

7 files changed

+41
-16
lines changed

7 files changed

+41
-16
lines changed

doc/_templates/mpl_nav_bar.html

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<ul id="navbar-main-elements" class="navbar-nav">
2+
3+
<li class="nav-item">
4+
<a class="reference internal nav-link" href="{{ pathto('plot_types/index') }}">Plot Types</a>
5+
</li>
6+
<li class="nav-item">
7+
<a class="reference internal nav-link" href="{{ pathto('gallery/index') }}">Examples</a>
8+
</li>
9+
<li class="nav-item">
10+
<a class="reference internal nav-link" href="{{ pathto('tutorials/index') }}">Tutoraials</a>
11+
</li>
12+
<li class="nav-item">
13+
<a class="reference internal nav-link" href="{{ pathto('api/index') }}">Reference</a>
14+
</li>
15+
<li class="nav-item">
16+
<a class="reference internal nav-link" href="{{ pathto('contents') }}">Usage Guide</a>
17+
</li>
18+
<li class="nav-item">
19+
<a class="reference internal nav-link" href="{{ pathto('devel/index') }}">Develop</a>
20+
</li>
21+
<li class="nav-item">
22+
<a class="reference internal nav-link" href="{{ pathto('users/release_notes') }}">Release Notes</a>
23+
</li>
24+
</ul>

doc/conf.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -323,6 +323,7 @@ def _check_dependencies():
323323
},
324324
],
325325
"show_prev_next": False,
326+
"navbar_center": ["mpl_nav_bar.html"],
326327
}
327328
include_analytics = False
328329
if include_analytics:

doc/contents.rst

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,10 @@ Contents
1414
.. toctree::
1515
:maxdepth: 2
1616

17-
plot_types/index.rst
18-
gallery/index.rst
19-
tutorials/index.rst
20-
api/index.rst
17+
users/installing.rst
2118
users/index.rst
19+
users/backmatter.rst
20+
devel/index.rst
2221
users/release_notes.rst
2322

2423
.. only:: html

doc/faq/index.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
.. _faq-index:
22

3-
##################
4-
The Matplotlib FAQ
5-
##################
3+
######
4+
How-To
5+
######
66

77
.. only:: html
88

doc/users/backmatter.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

2-
Back Matter
3-
-----------
2+
Project Information
3+
-------------------
44

55
.. toctree::
66
:maxdepth: 1

doc/users/index.rst

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
.. _users-guide-index:
22

3-
##########
4-
User guide
5-
##########
3+
###########
4+
Usage Guide
5+
###########
66

77
.. only:: html
88

@@ -13,11 +13,12 @@ User guide
1313

1414

1515
.. toctree::
16-
:maxdepth: 3
16+
:maxdepth: 2
1717

18-
installing.rst
18+
../plot_types/index.rst
19+
../tutorials/index.rst
20+
../gallery/index.rst
1921
explain.rst
2022
../faq/index.rst
23+
../api/index.rst
2124
../resources/index.rst
22-
backmatter.rst
23-
../devel/index.rst

examples/user_interfaces/test.bmp

781 KB
Binary file not shown.

0 commit comments

Comments
 (0)
0