fix #2379 - Keyword args rendered with type links, as normal parameters (configurable under napoleon_use_keyword option)

This commit is contained in:
Jan Duzinkiewicz
2016-03-15 21:24:16 +01:00
parent 15d89a2bfe
commit d8cd3ec4be
4 changed files with 102 additions and 18 deletions

View File

@@ -371,6 +371,22 @@ enabled in `conf.py`::
* **arg2** (*int, optional*) --
Description of `arg2`, defaults to 0
.. confval:: napoleon_use_keyword
True to use a ``:keyword:`` role for each function keyword argument.
False to use a single ``:keyword arguments:`` role for all the
keywords.
*Defaults to True.*
This behaves similarly to :attr:`napoleon_use_param`. Note unlike docutils,
``:keyword:`` and ``:param:`` will not be treated the same way - there will
be a separate "Keyword Arguments" section, rendered in the same fashion as
"Parameters" section (type links created if possible)
.. seealso::
:attr:`napoleon_use_param`
.. confval:: napoleon_use_rtype
True to use the ``:rtype:`` role for the return type. False to output