rewrapping paragraphs when over 80 characters wide

This commit is contained in:
EricFromCanada
2014-06-18 11:53:25 -04:00
parent 8981b9bd13
commit 65e924a3e4
23 changed files with 120 additions and 106 deletions

View File

@@ -274,13 +274,14 @@ inserting them into the page source under a suitable :rst:dir:`py:module`,
"""Docstring for instance attribute spam."""
.. versionchanged:: 0.6
:rst:dir:`autodata` and :rst:dir:`autoattribute` can now extract docstrings.
:rst:dir:`autodata` and :rst:dir:`autoattribute` can now extract
docstrings.
.. versionchanged:: 1.1
Comment docs are now allowed on the same line after an assignment.
.. versionchanged:: 1.2
:rst:dir:`autodata` and :rst:dir:`autoattribute` have
an ``annotation`` option
:rst:dir:`autodata` and :rst:dir:`autoattribute` have an ``annotation``
option.
.. note::
@@ -413,8 +414,8 @@ autodoc provides the following additional events:
``noindex`` that are true if the flag option of same name was given to the
auto directive
:param signature: function signature, as a string of the form
``"(parameter_1, parameter_2)"``, or ``None`` if introspection didn't succeed
and signature wasn't specified in the directive.
``"(parameter_1, parameter_2)"``, or ``None`` if introspection didn't
succeed and signature wasn't specified in the directive.
:param return_annotation: function return annotation as a string of the form
``" -> annotation"``, or ``None`` if there is no return annotation
@@ -445,8 +446,8 @@ member should be included in the documentation by using the following event:
``"attribute"``)
:param name: the fully qualified name of the object
:param obj: the object itself
:param skip: a boolean indicating if autodoc will skip this member if the user
handler does not override the decision
:param skip: a boolean indicating if autodoc will skip this member if the
user handler does not override the decision
:param options: the options given to the directive: an object with attributes
``inherited_members``, ``undoc_members``, ``show_inheritance`` and
``noindex`` that are true if the flag option of same name was given to the

View File

@@ -15,15 +15,15 @@ one of them on a separate page makes them easier to read.
The :mod:`sphinx.ext.autosummary` extension does this in two parts:
1. There is an :rst:dir:`autosummary` directive for generating summary listings that
contain links to the documented items, and short summary blurbs extracted
from their docstrings.
1. There is an :rst:dir:`autosummary` directive for generating summary listings
that contain links to the documented items, and short summary blurbs
extracted from their docstrings.
2. Optionally, the convenience script :program:`sphinx-autogen` or the new
:confval:`autosummary_generate` config value can be used to generate short
"stub" files for the entries listed in the :rst:dir:`autosummary` directives.
These files by default contain only the corresponding :mod:`sphinx.ext.autodoc`
directive, but can be customized with templates.
These files by default contain only the corresponding
:mod:`sphinx.ext.autodoc` directive, but can be customized with templates.
.. rst:directive:: autosummary
@@ -62,8 +62,8 @@ The :mod:`sphinx.ext.autosummary` extension does this in two parts:
**Options**
* If you want the :rst:dir:`autosummary` table to also serve as a :rst:dir:`toctree`
entry, use the ``toctree`` option, for example::
* If you want the :rst:dir:`autosummary` table to also serve as a
:rst:dir:`toctree` entry, use the ``toctree`` option, for example::
.. autosummary::
:toctree: DIRNAME
@@ -78,8 +78,8 @@ The :mod:`sphinx.ext.autosummary` extension does this in two parts:
directory. If no argument is given, output is placed in the same directory
as the file that contains the directive.
* If you don't want the :rst:dir:`autosummary` to show function signatures in the
listing, include the ``nosignatures`` option::
* If you don't want the :rst:dir:`autosummary` to show function signatures in
the listing, include the ``nosignatures`` option::
.. autosummary::
:nosignatures:
@@ -112,8 +112,8 @@ For example, the command ::
$ sphinx-autogen -o generated *.rst
will read all :rst:dir:`autosummary` tables in the :file:`*.rst` files that have the
``:toctree:`` option set, and output corresponding stub pages in directory
will read all :rst:dir:`autosummary` tables in the :file:`*.rst` files that have
the ``:toctree:`` option set, and output corresponding stub pages in directory
``generated`` for all documented items. The generated pages by default contain
text of the form::

View File

@@ -142,8 +142,8 @@ names.
The following is an example for the usage of the directives. The test via
:rst:dir:`doctest` and the test via :rst:dir:`testcode` and :rst:dir:`testoutput` are
equivalent. ::
:rst:dir:`doctest` and the test via :rst:dir:`testcode` and
:rst:dir:`testoutput` are equivalent. ::
The parrot module
=================
@@ -236,5 +236,5 @@ There are also these config values for customizing the doctest extension:
Note though that you can't have blank lines in reST doctest blocks. They
will be interpreted as one block ending and another one starting. Also,
removal of ``<BLANKLINE>`` and ``# doctest:`` options only works in
:rst:dir:`doctest` blocks, though you may set :confval:`trim_doctest_flags` to
achieve that in all code blocks with Python console content.
:rst:dir:`doctest` blocks, though you may set :confval:`trim_doctest_flags`
to achieve that in all code blocks with Python console content.

View File

@@ -99,8 +99,8 @@ linking:
This will read the inventory from :file:`python-inv.txt` in the source
directory, but still generate links to the pages under
``http://docs.python.org/3.2``. It is up to you to update the inventory file as
new objects are added to the Python documentation.
``http://docs.python.org/3.2``. It is up to you to update the inventory file
as new objects are added to the Python documentation.
.. confval:: intersphinx_cache_limit

View File

@@ -31,7 +31,8 @@ function that returns an URL based on the object.
- ``py``: ``module`` (name of the module), ``fullname`` (name of the object)
- ``c``: ``names`` (list of names for the object)
- ``cpp``: ``names`` (list of names for the object)
- ``javascript``: ``object`` (name of the object), ``fullname`` (name of the item)
- ``javascript``: ``object`` (name of the object), ``fullname``
(name of the item)
Example:

View File

@@ -61,8 +61,8 @@ source code files.
Getting Started
---------------
1. After :doc:`setting up Sphinx <../tutorial>` to build your docs, enable napoleon in the
Sphinx `conf.py` file::
1. After :doc:`setting up Sphinx <../tutorial>` to build your docs, enable
napoleon in the Sphinx `conf.py` file::
# conf.py

View File

@@ -26,5 +26,5 @@ There is also an additional config value:
.. confval:: todo_include_todos
If this is ``True``, :rst:dir:`todo` and :rst:dir:`todolist` produce output, else
they produce nothing. The default is ``False``.
If this is ``True``, :rst:dir:`todo` and :rst:dir:`todolist` produce output,
else they produce nothing. The default is ``False``.

View File

@@ -16,4 +16,5 @@ descriptions that leads to the source code of the described object. A link back
from the source to the description will also be inserted.
There are currently no configuration values for this extension; you just need to
add ``'sphinx.ext.viewcode'`` to your :confval:`extensions` value for it to work.
add ``'sphinx.ext.viewcode'`` to your :confval:`extensions` value for it to
work.