Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

技巧分享:Alfred Workflows 调用 Saladict 实现全局【文本翻译】 #509

Open
xinshangshangxin opened this issue Oct 10, 2019 · 9 comments
Labels

Comments

@xinshangshangxin
Copy link

@xinshangshangxin xinshangshangxin commented Oct 10, 2019

下载

saladict_v1.1

效果图

Jietu20191010-154129

Jietu20191010-162724

使用/配置

  1. 开启独立窗口快捷查词
    image

  2. 设置Saladict 独立窗口快捷键ctrl + cmd + L

image

  1. 解压上面下载的 saladict.alfredworkflow.zip, 双击 saladict.alfredworkflow 导入至 alfred workflow

  2. 双击 hotkey 录入快捷键
    image

  3. 选中文字, 触发快捷键即可 调用沙拉查询

以下为可选配置

  1. Saladict 独立窗口快捷键 设置的如果不是 ctrl + cmd + L, 则在 alfred 中双击 Run NSAppleScript
    image

修改截图所示代码, 其中 的 code 对应表请查看 complete-list-of-applescript-key-codes

image

比如 想要修改成 option + T, 那就把
key code 37 using {control down, command down} 改成
key code 17 using {option down}

说明

感谢作者针对 #485 进行加强, 才能使本脚本工作

参考文档

@crimx

This comment has been minimized.

Copy link
Owner

@crimx crimx commented Oct 10, 2019

谢谢,非常棒的分享!

@crimx crimx added the 👍Tips label Oct 10, 2019
@crimx crimx pinned this issue Oct 10, 2019
@crimx

This comment has been minimized.

Copy link
Owner

@crimx crimx commented Oct 10, 2019

新增的快捷键可以直接让沙拉查词查询剪贴板,不知对你的 workflow 有没有帮助。

@xinshangshangxin

This comment was marked as resolved.

Copy link
Author

@xinshangshangxin xinshangshangxin commented Oct 10, 2019

可以大幅度简化脚本, 回头我更新下

@xinshangshangxin

This comment was marked as resolved.

Copy link
Author

@xinshangshangxin xinshangshangxin commented Oct 10, 2019

已更新成1.1 版本, 调用 新增的快捷键 来实现

@nb5p

This comment has been minimized.

Copy link

@nb5p nb5p commented Oct 17, 2019

新增的快捷键可以直接让沙拉查词查询剪贴板,不知对你的 workflow 有没有帮助。

这个只能查剪切板的不太方便,有没有可能改成接受脚本传来的参数

@crimx

This comment has been minimized.

Copy link
Owner

@crimx crimx commented Oct 17, 2019

我可以让沙拉查词响应事件,如果你有兴趣欢迎另开 issue 我们讨论一下接口设计。

@crimx

This comment was marked as outdated.

Copy link
Owner

@crimx crimx commented Oct 30, 2019

@qq645381995 请不要搭楼反馈不相关问题。

@qq645381995

This comment has been minimized.

Copy link

@qq645381995 qq645381995 commented Oct 30, 2019

image
主要我这怎么没反应呢?

@nb5p

This comment has been minimized.

Copy link

@nb5p nb5p commented Oct 30, 2019

image
主要我这怎么没反应呢?

建议仔细阅读,需要设置快捷键,使用快捷键呼出沙拉查词并检索剪切板中的内容

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.