Add rst:directive:option directive

This commit is contained in:
Takeshi KOMIYA
2019-04-13 11:00:16 +09:00
parent e32a610d7a
commit 4307dec3ac
4 changed files with 133 additions and 2 deletions

View File

@@ -1423,6 +1423,29 @@ The reStructuredText domain (name **rst**) provides the following directives:
Bar description.
.. rst:directive:: .. rst:directive:option:: name
Describes an option for reST directive. The *name* can be a single option
name or option name with arguments which separated with colon (``:``).
For example::
.. rst:directive:: toctree
.. rst:directive:option:: caption: caption of ToC
.. rst:directive:option:: glob
will be rendered as:
.. rst:directive:: toctree
:noindex:
.. rst:directive:option:: caption: caption of ToC
.. rst:directive:option:: glob
.. versionadded:: 2.1
.. rst:directive:: .. rst:role:: name
Describes a reST role. For example::