自从我处理了Applescript以来,这已经过了很多年了,所以在这里进行了一些高级的道歉操作。用Appleccript记录窗口的边界(尺寸)
使用下面的代码片段,我可以调整窗口大小
tell application "BBEdit"
activate
set the bounds of the first window to {100, 0, 700, 700}
end tell
我感兴趣的是使用类似的语句来读取,然后登录第一窗口的范围。我试图
tell application "BBEdit"
activate
log (the bounds of the first window)
set wSize to the bounds of the first window
log wSize
end tell
但事件日志中列出
(*bounds of window 1*)
每次
。我期待更多的东西
{100, 0, 700, 700}
我最终的目标是创建一个变量,其中包含窗口边界,并以编程方式操纵值。第一步是学习如何正确记录数值。
那么,如何在Apple的脚本编辑器中记录窗口应用程序的边界。