【发布时间】:2012-04-24 20:19:36
【问题描述】:
我想在终端中列出打开的窗口以获取 x、y、宽度和高度,如 X11 的 xwininfo -root -tree。
我试过了:
osacript -e tell application "Microsoft Word" to get the bounds of the front window
但它不适用于所有应用程序,并且您不能指定子级(如果您有两个 Word 文档,它会返回第一个打开的文档)。
【问题讨论】:
标签: macos applescript osascript