Example #1
0
File: passes.py Project: xcore/xdoc
def format_references(app, doctree, docname):
    for node in doctree.traverse(nodes.reference):
        text = node[0].astext()
        node.pop(0)
        node += miniparse(text)
Example #2
0
File: xroles.py Project: xcore/xdoc
def tt(role, rawtext, text, lineno, inliner, options={}, content={}):
    node = nodes.inline()
    node['classes'].append('tt')
    node += miniparse(rawtext[5:-1])
    return [node],[]
Example #3
0
File: xroles.py Project: xcore/xdoc
def subscript(role, rawtext, text, lineno, inliner, options={}, content={}):
    sub = nodes.subscript()
    sub += miniparse(text)
    return [sub],[]
Example #4
0
File: xroles.py Project: xcore/xdoc
def command(role, rawtext, text, lineno, inliner, options={}, content={}):
    node = nodes.inline()
    node['classes'].append('cmd')
    node += miniparse(text)
    return [node],[]