Is it possible to ask an OS开发者_如何学PythonX application which applescript commands it responds to, and if so, how?
You need to look at the Dictionary for an application to see all of the classes and commands the application supports. To get to an application's Dictionary in the the Applescript Editor go to File > Open Dictionary...
. A list of all the applications that the OS knows supports Applescript will appear, but the OS won't catch them all so you can use the Browse button. If an application doesn't support Applescript, then it won't be selectable in the dialog window.
The caveat to this is that there are certain commands that an application is supposed to support but don't, or an application may only support the minimum requirements. These are all very, very simple like open
, quit
, etc. Your mileage may vary.
精彩评论