使用 applescripts 在空间中打开应用程序 [英] Open an application in a space using applescripts

查看:54
本文介绍了使用 applescripts 在空间中打开应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试创建一个脚本,该脚本将在特定空间"中打开应用程序.因此,假设我在终端的空间 1 上工作,然后我希望能够在空间 4 中打开 safari.有没有办法做到这一点?

I am trying to create a script that will open an application in a specific "space". So let's say I am on space 1 working in the terminal and then I want to be able to open safari in space 4. Is there a way to do this?

我进行了一些搜索,只找到了设置系统配置文件选项的方法.也许我应该告诉你我的最终目标,以防我尝试的事情是不可能的.

I have done some searching and found only ways to set the system profile options. Maybe I should tell you my end goal in case what I am attempting is not possible.

我使用笔记本电脑和插件访问多个站点、家庭、办公室和旅行.我想为每一个创建不同的窗口布局.所以我需要一个苹果脚本,告诉它在不同的空间和不同的维度中打开应用程序.我希望这是有道理的.如果没有,请向我说明,谢谢!

I use a laptop and plugin in to multiple stations, home, office, and travel. I want to create different window layouts for each one. So I will need an apple script telling it to open applications in varios spaces and different dimensions. I hope this makes sense. Ask me for clarification if it doesn't thanks!

PS 答案不一定必须是任何苹果脚本,我只是认为这是最简单的方法 :)

PS the answer doesn't necessarily have to be any applescript I just thought that would be the easiest way :)

推荐答案

通过使用 System Events.app<的脚本接口,可以对应用程序 Space 首选项进行一些脚本编写/代码>.在此处查看类似问题的答案.

It is possible to do some scripting of application Space preferences by using the scripting interface to the System Events.app. See the answer to a similar question here.

这篇关于使用 applescripts 在空间中打开应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆