def _quoteattr(data, entities={}):
    data = _escape(data, entities)
    if '"' in data:
        if "'" in data:
            data = '"%s"' % data.replace('"', "&quot;")
        else:
            data = "'%s'" % data
    else:
        data = '"%s"' % data
    return data
Convert a Sublime View into an SWIDebugView
dataset/ETHPy150Open CGATOxford/cgat/CGAT/SVGdraw.py/_quoteattr--crossover with--dataset/ETHPy150Open sokolovstas/SublimeWebInspector/views.py/wrap_view