def xfunc(nd): s = nd.nextSibling.textContent n = nd.tagName if s: if s[0] not in {'(', '[', '{'}: getap(nd).append(txt.pmtr(n + u'\u2006')) else: getap(nd).append(txt.pmtr(n)) else: getap(nd).append(txt.pmtr(n))
def xfunc(nd): s = nd.nextSibling.textContent n = nd.tagName if s: if s[0] not in {"(", "[", "{"}: getap(nd).append(txt.pmtr(n + u"\u2006")) else: getap(nd).append(txt.pmtr(n)) else: getap(nd).append(txt.pmtr(n))
def limlow(nd, s): ll = etree.Element(NSM + 'limLow') e = etree.SubElement(ll, NSM + 'e') e.append(txt.pmtr(s)) l = etree.SubElement(ll, NSM + 'lim') getap(nd).append(ll) ns = nd.nextSibling if ns.nodeName == 'active::_': setap(ns, l) ct.cnl(ns) nd.parentNode.removeChild(ns)
def limlow(nd, s): ll = etree.Element(NSM + "limLow") e = etree.SubElement(ll, NSM + "e") e.append(txt.pmtr(s)) l = etree.SubElement(ll, NSM + "lim") getap(nd).append(ll) ns = nd.nextSibling if ns.nodeName == "active::_": setap(ns, l) ct.cnl(ns) nd.parentNode.removeChild(ns)