def getaetedata(appname): if _osaxpathsbyname.has_key(appname.lower()): return getaete(_osaxpathsbyname[appname.lower()]) elif appname.startswith('eppc://'): return terminology.aetedataforapp(aem.Application(url=appname)) else: return getaete(aem.findapp.byname(appname))
def app(path, out=sys.stdout, converter=None): """Render raw terminology for application. path : str -- full path to application out : file -- open file object to write to (default: stdout) converter : function -- function to convert AppleScript-style keywords (default: None) """ data = getaete(path) parse(data, QuickDoc(out, converter))
def parseapp(path, style='appscript'): return parseaetes(getaete(path), path, style)