How do I communicate between python and a mac application?

后端 未结 5 1832
慢半拍i
慢半拍i 2021-01-20 20:34

This might be a vague question, but I failed to rephrase it properly. So here\'s an explanation.

I developed an app that was originally developed as a Mac applicatio

5条回答
  •  遇见更好的自我
    2021-01-20 21:14

    On osx, many native applications support AppleScript (aka OSA) as their native scripting API. Thus your question becomes one of interacting between Python and Applescript (and figuring out how to talk to your target application in AppleScript in the first place).

    There is some OSA support in the Python standard library and a third-party module py-applescript you might want to look at.

提交回复
热议问题