Skip to content

Commit 5580ae2

Browse files
committed
DOC: heading style
1 parent 7814ada commit 5580ae2

6 files changed

Lines changed: 71 additions & 28 deletions

File tree

doc/devel/coding_guide.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -190,8 +190,8 @@ local arguments and the rest are passed on as
190190

191191
.. _using_logging:
192192

193-
Using logging for debug messages
194-
================================
193+
Use logging for debug messages
194+
==============================
195195

196196
Matplotlib uses the standard Python `logging` library to write verbose
197197
warnings, information, and debug messages. Please use it! In all those places

doc/devel/min_dep_policy.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,8 +157,8 @@ Matplotlib Python NumPy
157157
.. _`1.3`: https://matplotlib.org/1.3.0/users/installing.html#build-requirements
158158

159159

160-
Updating Python and NumPy versions
161-
==================================
160+
Update Python and NumPy versions
161+
================================
162162

163163
To update the minimum versions of Python we need to update:
164164

doc/devel/release_guide.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ versioning scheme: *macro.meso.micro*.
4545

4646
.. _release_feature_freeze:
4747

48-
Making the release branch
48+
Create the release branch
4949
=========================
5050

5151
.. note::
@@ -379,8 +379,8 @@ to the VER-doc branch and push to GitHub. ::
379379

380380
.. _release_bld_bin:
381381

382-
Building binaries
383-
=================
382+
Build binaries
383+
==============
384384

385385
We distribute macOS, Windows, and many Linux wheels as well as a source tarball via
386386
PyPI.
@@ -412,8 +412,8 @@ PyPI.
412412

413413
.. _release_upload_bin:
414414

415-
Manually uploading to PyPI
416-
==========================
415+
Manual upload to PyPI
416+
=====================
417417

418418
.. note::
419419

doc/devel/style_guide.rst

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,49 @@ reliability and consistency in documentation. They are not interchangeable.
176176
.. |Axis| replace:: :class:`~matplotlib.axis.Axis`
177177

178178

179+
Headings
180+
--------
181+
Use sentence case for headings.
182+
183+
.. table::
184+
:width: 100%
185+
:widths: 50, 50
186+
187+
+------------------------------------+------------------------------------+
188+
| Correct | Incorrect |
189+
+====================================+====================================+
190+
| Quick start guide | Quick Start Guide |
191+
+------------------------------------+------------------------------------+
192+
193+
Noun phrases and verb phrases are both acceptable for headings. For high-level
194+
headings or if in doubt, prefer noun phrases.
195+
196+
.. table::
197+
:width: 100%
198+
:widths: 50, 50
199+
200+
+------------------------------------+------------------------------------+
201+
| Correct | Incorrect |
202+
+====================================+====================================+
203+
| Bug triage and issue curation | Triage bugs and curate issues |
204+
+------------------------------------+------------------------------------+
205+
206+
Verb phrases are good for action-oriented headings, in particular when they
207+
cover steps in a process, such as the subsections in :ref:`installing_for_devs`.
208+
209+
Use the second-person imperative form of the verb rather than the gerund form.
210+
211+
.. table::
212+
:width: 100%
213+
:widths: 50, 50
214+
215+
+------------------------------------+------------------------------------+
216+
| Correct | Incorrect |
217+
+====================================+====================================+
218+
| Fork the Matplotlib repository | Forking the Matplotlib repository |
219+
+------------------------------------+------------------------------------+
220+
221+
179222
Grammar
180223
-------
181224

doc/devel/testing.rst

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@ particular the :ref:`additional dependencies <test-dependencies>` for testing.
3434

3535
.. _run_tests:
3636

37-
Running the tests
38-
-----------------
37+
Run the tests
38+
-------------
3939

4040
In the root directory of your development repository run::
4141

@@ -82,8 +82,8 @@ to avoid clashes between ``pytest``'s import mode and Python's search path:
8282

8383
python -m pytest --import-mode prepend
8484

85-
Viewing image test output
86-
^^^^^^^^^^^^^^^^^^^^^^^^^
85+
View image test output
86+
^^^^^^^^^^^^^^^^^^^^^^
8787

8888
The output of :ref:`image-based <image-comparison>` tests is stored in a
8989
``result_images`` directory. These images can be compiled into one HTML page, containing
@@ -100,8 +100,8 @@ to the folder where the baseline test images are stored. The triage tool require
100100
:ref:`QT <backend_dependencies>` is installed.
101101

102102

103-
Writing tests
104-
-------------
103+
Write tests
104+
-----------
105105
Tests are located in :file:`lib/matplotlib/tests`. They are organized to mirror
106106
the structure of the code in :file:`lib/matplotlib`. For example, tests for
107107
the ``mathtext.py`` module are in :file:`lib/matplotlib/tests/test_mathtext.py`.
@@ -284,8 +284,8 @@ See the documentation of `~matplotlib.testing.decorators.image_comparison` and
284284
`~matplotlib.testing.decorators.check_figures_equal` for additional information
285285
about their use.
286286

287-
Using GitHub Actions for CI
288-
---------------------------
287+
CI with GitHub Actions
288+
----------------------
289289

290290
`GitHub Actions <https://docs.github.com/en/actions>`_ is a hosted CI system
291291
"in the cloud".
@@ -311,8 +311,8 @@ https://github.com/your_GitHub_user_name/matplotlib/actions -- here's `an
311311
example <https://github.com/QuLogic/matplotlib/actions>`_.
312312

313313

314-
Using tox
315-
---------
314+
tox: Test multiple python versions
315+
----------------------------------
316316

317317
`Tox <https://tox.readthedocs.io/en/latest/>`_ is a tool for running tests
318318
against multiple Python environments, including multiple versions of Python
@@ -352,17 +352,17 @@ tests are run. For more info on the ``tox.ini`` file, see the `Tox
352352
Configuration Specification
353353
<https://tox.readthedocs.io/en/latest/config.html>`_.
354354

355-
Building old versions of Matplotlib
356-
-----------------------------------
355+
Build old versions of Matplotlib
356+
--------------------------------
357357

358358
When running a ``git bisect`` to see which commit introduced a certain bug,
359359
you may (rarely) need to build very old versions of Matplotlib. The following
360360
constraints need to be taken into account:
361361

362362
- Matplotlib 1.3 (or earlier) requires numpy 1.8 (or earlier).
363363

364-
Testing released versions of Matplotlib
365-
---------------------------------------
364+
Test released versions of Matplotlib
365+
------------------------------------
366366
Running the tests on an installation of a released version (e.g. PyPI package
367367
or conda package) also requires additional setup.
368368

doc/devel/triage.rst

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

22
.. _bug_triaging:
33

4-
*******************************
5-
Bug triaging and issue curation
6-
*******************************
4+
*****************************
5+
Bug triage and issue curation
6+
*****************************
77

88
The `issue tracker <https://github.com/matplotlib/matplotlib/issues>`_
99
is important to communication in the project because it serves as the
@@ -107,8 +107,8 @@ important tasks:
107107
question or has been considered as unclear for many years, then it
108108
should be closed.
109109

110-
Preparing PRs for review
111-
========================
110+
Prepare PRs for review
111+
======================
112112

113113
Reviewing code is also encouraged. Contributors and users are welcome to
114114
participate to the review process following our :ref:`review guidelines

0 commit comments

Comments
 (0)