Doctree node classes added by Sphinx¶
Nodes for domain-specific object descriptions¶
-
class
sphinx.addnodes.
desc
(rawsource='', *children, **attributes)[source]¶ Node for object descriptions.
This node is similar to a “definition list” with one definition. It contains one or more
desc_signature
and adesc_content
.
-
class
sphinx.addnodes.
desc_signature
(rawsource='', text='', *children, **attributes)[source]¶ Node for object signatures.
The “term” part of the custom Sphinx definition list.
-
class
sphinx.addnodes.
desc_addname
(rawsource='', text='', *children, **attributes)[source]¶ Node for additional name parts (module name, class name).
-
class
sphinx.addnodes.
desc_type
(rawsource='', text='', *children, **attributes)[source]¶ Node for return types or object type names.
-
class
sphinx.addnodes.
desc_returns
(rawsource='', text='', *children, **attributes)[source]¶ Node for a “returns” annotation (a la -> in Python).
-
class
sphinx.addnodes.
desc_name
(rawsource='', text='', *children, **attributes)[source]¶ Node for the main object name.
-
class
sphinx.addnodes.
desc_parameterlist
(rawsource='', text='', *children, **attributes)[source]¶ Node for a general parameter list.
-
class
sphinx.addnodes.
desc_parameter
(rawsource='', text='', *children, **attributes)[source]¶ Node for a single parameter.
-
class
sphinx.addnodes.
desc_optional
(rawsource='', text='', *children, **attributes)[source]¶ Node for marking optional parts of the parameter list.
New admonition-like constructs¶
Other paragraph-level nodes¶
New inline nodes¶
-
class
sphinx.addnodes.
index
(rawsource='', text='', *children, **attributes)[source]¶ Node for index entries.
This node is created by the
index
directive and has one attribute,entries
. Its value is a list of 4-tuples of(entrytype, entryname, target, ignored)
.entrytype is one of “single”, “pair”, “double”, “triple”.
-
class
sphinx.addnodes.
pending_xref
(rawsource='', *children, **attributes)[source]¶ Node for cross-references that cannot be resolved without complete information about all documents.
These nodes are resolved before writing output, in BuildEnvironment.resolve_references.
-
class
sphinx.addnodes.
literal_emphasis
(rawsource='', text='', *children, **attributes)[source]¶ Node that behaves like emphasis, but further text processors are not applied (e.g. smartypants for HTML output).
Special nodes¶
-
class
sphinx.addnodes.
only
(rawsource='', *children, **attributes)[source]¶ Node for “only” directives (conditional inclusion based on tags).
-
class
sphinx.addnodes.
meta
(rawsource='', *children, **attributes)[source]¶ Node for meta directive – same as docutils’ standard meta node, but pickleable.
-
class
sphinx.addnodes.
highlightlang
(rawsource='', *children, **attributes)[source]¶ Inserted to set the highlight language and line number options for subsequent code blocks.
You should not need to generate the nodes below in extensions.
-
class
sphinx.addnodes.
glossary
(rawsource='', *children, **attributes)[source]¶ Node to insert a glossary.
-
class
sphinx.addnodes.
toctree
(rawsource='', *children, **attributes)[source]¶ Node for inserting a “TOC tree”.
-
class
sphinx.addnodes.
start_of_file
(rawsource='', *children, **attributes)[source]¶ Node to mark start of a new file, used in the LaTeX builder only.
-
class
sphinx.addnodes.
productionlist
(rawsource='', *children, **attributes)[source]¶ Node for grammar production lists.
Contains
production
nodes.