zoukankan      html  css  js  c++  java
  • 使用AutoHotKey基本实现CapLock+

    起因

    因为使用公司的电脑无法使用CapLock+这款插件,所以通过自己编写的AutoHotKey脚本去实现CapLock+这款插件的大概功能

    脚本文件

    #NoEnv  ; Recommended for performance and compatibility with future AutoHotkey releases.
    ; #Warn  ; Enable warnings to assist with detecting common errors.
    SendMode Input  ; Recommended for new scripts due to its superior speed and reliability.
    SetWorkingDir %A_ScriptDir%  ; Ensures a consistent starting directory.
    
    
    ;上下左右
    CapsLock & s::
    Send {Left}
    return
     
    CapsLock & f::
    Send {Right}
    return
     
    CapsLock & e::   
    Send {Up}   
    return
     
    CapsLock & d::
    Send {Down}
    return
    
    ;行首
    CapsLock & `;::
    Send {End}
    return
    
    ;行尾
    CapsLock & p::
    Send {Home}
    return
    
    ;跳到行尾换行
    CapsLock & Enter::
    Send {End}{Enter}
    return
    
    ;删除当前行
    CapsLock & Backspace::
    Send {Home}{ShiftDown}{End}{Right}{ShiftUp}{Del}
    return
    
    ;选中当前行
    CapsLock & ,::
    Send {Home}{ShiftDown}{End}{ShiftUp}
    return
    
    ;选中上下左右行
    CapsLock & j::
    Send {ShiftDown}{Left}{ShiftUp}
    return
    
    CapsLock & l::
    Send {ShiftDown}{Right}{ShiftUp}
    return
    
    CapsLock & i::
    Send {ShiftDown}{Up}{ShiftUp}
    return
    
    CapsLock & k::
    Send {ShiftDown}{Down}{ShiftUp}
    return
    
    ;向前选中一个单词
    CapsLock & h::
    Send {ShiftDown}{CtrlDown}{Left}{CtrlUp}{ShiftUp}
    return
    
    ;置顶窗口
    CapsLock & 1:: 
    Winset, AlwaysOnTop, Toggle, A
    

    下载AutoHotKey后,直接双击打开此脚本文件即可使用,或使用AutoHotKey对其进行编译,生成exe文件。

  • 相关阅读:
    Twain文档链接
    JavaScript 事件绑定函数
    VC++ 字符串Dword、LPSTR、LPWSTR、LPCSTR、LPCWSTR、LPTSTR、LPCTSTR
    Sciter参考资料
    C++对windows控制面板的操作
    C++ Msi函数判断应用是否已经安装
    WMware 安装 Mac OSX
    C++文件流操作
    jquery弹出层
    CSS3 水平翻转
  • 原文地址:https://www.cnblogs.com/shouyaya/p/15019312.html
Copyright © 2011-2022 走看看