在windows下启用emacs 快捷键

这篇博客介绍了如何使用AutoHotkey脚本来管理应用程序的激活状态,特别是针对Chrome、Emacs、Cygwin等应用进行定制化的启用设置。脚本通过检查窗口活动状态来决定是否允许特定应用被激活,从而实现更高效的工作流程。
摘要由CSDN通过智能技术生成

1. https://www.autohotkey.com/

2. 下载ahk

3. 修改脚本,Return 0是在该应用启用,如chrome中启用

is_target()
{
  IfWinActive,ahk_exe chrome.exe
    Return 0
  IfWinActive,ahk_class emacs
    Return 0
  IfWinActive,ahk_class runemacs
    Return 0
  IfWinActive,ahk_exe Explorer.exe
    Return 1
  IfWinActive,ahk_exe WindowsTerminal.exe
    Return 0
  IfWinActive,ahk_class ConsoleWindowClass ; Cygwin
    Return 1 
  IfWinActive,ahk_class MEADOW ; Meadow
    Return 1 
  IfWinActive,ahk_class cygwin/x X rl-xterm-XTerm-0
    Return 1
  IfWinActive,ahk_class MozillaUIWindowClass ; keysnail on Firefox
    Return 1
  ; Avoid VMwareUnity with AutoHotkey
  IfWinActive,ahk_class VMwareUnityHostWndClass
    Return 1
  IfWinActive,ahk_class Vim ; GVIM
    Return 1
  IfWinActive,ahk_exe Code.exe
    Return 1
  IfWinActive,ahk_class mintty
    Return 1
  Return 1
}
 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值