from docutils import nodes
from docutils.parsers.rst import directives
-
-from compat import (
- CompatField,
- CompatGroupedField,
- CompatTypedField,
- KeywordNode,
- ParserFix,
- Signature,
- SpaceNode,
-)
from sphinx import addnodes
from sphinx.directives import ObjectDescription
from sphinx.domains import (
from sphinx.util.docutils import SphinxDirective
from sphinx.util.nodes import make_id, make_refnode
+from compat import (
+ CompatField,
+ CompatGroupedField,
+ CompatTypedField,
+ KeywordNode,
+ ParserFix,
+ Signature,
+ SpaceNode,
+)
+
if TYPE_CHECKING:
from typing import (
)
from docutils.nodes import Element, Node
-
from sphinx.addnodes import desc_signature, pending_xref
from sphinx.application import Sphinx
from sphinx.builders import Builder
"""
def handle_signature(self, sig: str, signode: desc_signature) -> Signature:
+ # pylint: disable=unused-argument
+
# Do nothing. The return value here is the "name" of the entity
# being documented; for QAPI, this is the same as the
# "signature", which is just a name.
def add_target_and_index(
self, name: Signature, sig: str, signode: desc_signature
) -> None:
+ # pylint: disable=unused-argument
+
# name is the return value of handle_signature.
# sig is the original, raw text argument to handle_signature.
# For QAPI, these are identical, currently.
from __future__ import annotations
+
__version__ = "2.0"
from contextlib import contextmanager
QAPISchemaVisitor,
)
from qapi.source import QAPISourceInfo
-
-from qapidoc_legacy import QAPISchemaGenRSTVisitor # type: ignore
from sphinx import addnodes
from sphinx.directives.code import CodeBlock
from sphinx.errors import ExtensionError
from sphinx.util.docutils import SphinxDirective, switch_source_input
from sphinx.util.nodes import nested_parse_with_titles
+from qapidoc_legacy import QAPISchemaGenRSTVisitor # type: ignore
+
if TYPE_CHECKING:
from typing import (