def visit_inheritance_diagram(inner_func):
    def visitor(self, node):
        try:
            content = inner_func(self, node)
        except DotException as e:
            # Insert the exception as a warning in the document
            warning = self.document.reporter.warning(str(e), line=node.line)
            warning.parent = node
            node.children = [warning]
        else:
            source = self.document.attributes['source']
            self.body.append(content)
            node.children = []
    return visitor
Return the number of display cells `string` occupies.
dataset/ETHPy150Open ipython/ipython-py3k/docs/sphinxext/inheritance_diagram.py/visit_inheritance_diagram--crossover with--dataset/ETHPy150Open neovim/python-client/neovim/api/nvim.py/Nvim.strwidth