-3

我刚开始使用 AutoHotKey 并编写了简单的脚本

::o::email address

但是,要执行此文本更改,我按空格并在地址后输入一个空格。这会导致系统拒绝我的电子邮件。如果您能帮助我编写一个简单的 1 或 2 击键解决方案的脚本,让电子邮件地址输入没有尾随空格,那就太好了。如果它也tab能进入下一个领域,那就太好了。

谢谢!

4

1 回答 1

1

您使用的是单个字符的热字符串(大多数人会使用热键,但这也可以。

通常,热字符串由一些预定义的键(如 {Enter} 或 {Space})“完成”,但您可以自己定义这些“结束”字符。

不再需要结束字符的一种方法是在热字符串中使用一些控制符号。

::o::email address`t ; Your original, requires e.g. {Enter} or {Space}
:*:o::email address`t ; Does NOT require and end character. EVERYWHERE when I write an isolated "o", I get "email address"
:*?:o::email address`t ; Now the "oo" is not even isolate, but can be in a word like "more" becomes "memail addressre"

我这样做的方法是:

:*:o\::email address`t ; The "\" is next to my {Enter} key and when I type the combo "o\" I receive "email address"

可以在此处找到有关热字串的更多信息:http : //www.autohotkey.com/docs/Hotstrings.htm

于 2013-06-14T06:45:56.243 回答