Lines Matching +full:- +full:- +full:target +full:- +full:list
1 # D-Bus sphinx domain extension
5 # SPDX-License-Identifier: LGPL-2.1-or-later
7 # Author: Marc-André Lureau <marcandre.lureau@redhat.com>
14 List,
45 def get_index_text(self, modname: str, name: str) -> str:
51 ) -> None:
76 def get_index_text(self, ifacename: str, name: str) -> str:
79 def before_content(self) -> None:
82 def after_content(self) -> None:
85 def handle_signature(self, sig: str, signode: desc_signature) -> str:
90 def run(self) -> List[Node]:
93 section = nodes.section(ids=[name + "-section"])
116 doc_field_types: List[Field] = [
135 def get_index_text(self, ifacename: str, name: str) -> str:
138 def handle_signature(self, sig: str, signode: desc_signature) -> str:
174 doc_field_types: List[Field] = [
186 def get_index_text(self, ifacename: str, name: str) -> str:
202 "emits-changed": directives.unchanged,
206 doc_field_types: List[Field] = []
208 def get_index_text(self, ifacename: str, name: str) -> str:
211 def transform_content(self, contentnode: addnodes.desc_content) -> None:
215 access = _("read-only")
217 access = _("write-only")
226 emits = self.options.get("emits-changed", None)
236 def handle_signature(self, sig: str, signode: desc_signature) -> str:
247 def run(self) -> List[Node]:
253 def process_link(self, env, refnode, has_explicit_title, title, target): argument
256 title = title.lstrip(".") # only has a meaning for the target
257 target = target.lstrip("~") # only has a meaning for the title
263 if dot != -1:
267 if target[0:1] == ".":
268 target = target[1:]
270 return title, target
275 Index subclass to provide a D-Bus interfaces index.
279 localname = _("D-Bus Interfaces Index")
284 ) -> Tuple[List[Tuple[str, List[IndexEntry]]], bool]:
285 content: Dict[str, List[IndexEntry]] = {}
286 # list of prefixes to ignore
287 ignores: List[str] = self.domain.env.config["dbus_index_common_prefix"]
327 Implementation of the D-Bus domain.
331 label = "D-Bus"
351 "objects": {}, # fullname -> ObjectEntry
358 def objects(self) -> Dict[str, ObjectEntry]:
359 return self.data.setdefault("objects", {}) # fullname -> ObjectEntry
363 ) -> None:
366 def clear_doc(self, docname: str) -> None:
367 for fullname, obj in list(self.objects.items()):
371 def find_obj(self, typ: str, name: str) -> Optional[Tuple[str, ObjectEntry]]:
373 if name[-2:] == "()":
374 name = name[:-2]
388 target: str,
391 ) -> Optional[Element]:
392 """Resolve the pending_xref *node* with the given *typ* and *target*."""
393 objdef = self.find_obj(typ, target)
399 def get_objects(self) -> Iterator[Tuple[str, str, str, str, str, int]]: