0
对于我的学习,我使用很多screencapture功能作为终端命令。最近我开始使用AppleScript来自动化一些屏幕截图。但现在我想推进一点。AppleScript提示点击用户
是否有可能使用诸如“显示对话框”之类的命令,而是查询2次点击,其中坐标将被分配给screencapture命令,以便拍摄屏幕图片?
我在想是这样的:
set click1 to "0,0"
set click2 to "0,0"
display dialog "Click where the screen area to grab begins" & click1
display dialog "Click where the screen area to grab begins" & click2
do shell script "screencapture -R click1,click2 /Users/user/Desktop/name_of_the_file.png"