Exemplo n.º 1
0
def acks_directive(name, arguments, options, content, lineno,
                   content_offset, block_text, state, state_machine):
    node = addnodes.acks()
    state.nested_parse(content, content_offset, node)
    if len(node.children) != 1 or not isinstance(node.children[0], nodes.bullet_list):
        return [state.document.reporter.warning('.. acks content is not a list',
                                                line=lineno)]
    return [node]
Exemplo n.º 2
0
def acks_directive(name, arguments, options, content, lineno,
                   content_offset, block_text, state, state_machine):
    node = addnodes.acks()
    state.nested_parse(content, content_offset, node)
    if len(node.children) != 1 or not isinstance(node.children[0], nodes.bullet_list):
        return [state.document.reporter.warning('.. acks content is not a list',
                                                line=lineno)]
    return [node]
Exemplo n.º 3
0
 def run(self):
     node = addnodes.acks()
     node.document = self.state.document
     self.state.nested_parse(self.content, self.content_offset, node)
     if len(node.children) != 1 or not isinstance(node.children[0],
                                                  nodes.bullet_list):
         return [self.state.document.reporter.warning(
             '.. acks content is not a list', line=self.lineno)]
     return [node]
Exemplo n.º 4
0
 def run(self):
     node = addnodes.acks()
     node.document = self.state.document
     self.state.nested_parse(self.content, self.content_offset, node)
     if len(node.children) != 1 or not isinstance(node.children[0],
                                                  nodes.bullet_list):
         return [self.state.document.reporter.warning(
             '.. acks content is not a list', line=self.lineno)]
     return [node]
Exemplo n.º 5
0
 def run(self) -> List[Node]:
     node = addnodes.acks()
     node.document = self.state.document
     self.state.nested_parse(self.content, self.content_offset, node)
     if len(node.children) != 1 or not isinstance(node.children[0],
                                                  nodes.bullet_list):
         logger.warning(__('.. acks content is not a list'),
                        location=(self.env.docname, self.lineno))
         return []
     return [node]