class_docstr: Assemble, save, and render DOT source code, open result in viewer.
class_docstr_tok: ["Assemble",",","save",",","and","render","DOT","source","code",",","open","result","in","viewer","."]
docstr: Yield the DOT source code line by line (as graph or subgraph).
docstr_tok: ["Yield","the","DOT","source","code","line","by","line","(","as","graph","or","subgraph",")","."]
code: def __iter__(self, subgraph=False):
      """Yield the DOT source code line by line (as graph or subgraph)."""
      if self.comment:
          yield self._comment % self.comment
  
      if subgraph:
          if self.strict:
              raise ValueError("subgraphs cannot be strict")
          head = self._subgraph if self.name else self._subgraph_plain
      else:
          head = self._head_strict if self.strict else self._head
      yield head % (self._quote(self.name) + " " if self.name else "")
  
      for kw in ("graph", "node", "edge"):
          attrs = getattr(self, "%s_attr" % kw)
          if attrs:
              yield self._attr % (kw, self._attr_list(None, attrs))
  
      for line in self.body:
          yield line
  
      yield self._tail
  
imports: from .None import backend
  from .None import files
  from .None import lang
label_desc: Use image node_id 4 for calling the Dot obj's underlying member method code with example usage: obj.__iter__(subgraph) without return types