Home / Autohotkey.ini
Page options

Autohotkey.ini


  ; Win---># ; Shift--->+ ; Ctrl--->^ ; Alt--->!;::/d::此格式加回车执行
#include %A_scriptDir%\myahk\launch.ahk
#include %A_scriptDir%\myahk\winhide.ahk



^End:: 
    suspend ; AutoHotKey 挂起/激活双向开关 
    msgbox,64,激活 VS 挂起,^-^ AutoHotKey 挂起/激活双向开关 ^-^,0.2 
return
-----------------------关闭显示器---------------------------------- 
#q::
KeyWait q
KeyWait LWin ;释放左Win键才激活下面的命令
SendMessage,0x112,0xF170,2,,Program Manager ;关闭显示器。0x112:WM_SYSCOMMAND,0xF170:SC_MONITORPOWER。2:关闭,-1:开启显示器
Return
-------------------字符补全------------------------------
::/cw:: 
clipboard = call WaitMsg 
        ;把文字发送到剪贴板(Clipboard)(完美实现,不产生换行的副作用) 
Send ^v 
return
:*:goo::google
:*:<p>::<p></p>
:*:<l::<li></li>
:*:<pr::<pre></pre>
:*:<h1::<h1></h1>
:*:<h2::<h2></h2>
:*:<h3::<h3></h3>
:*:<h4::<h4></h4>
:*:<s::<strong></strong>
:*:<sp::<span style="color:red"></span>
---------------F1快速帮助--------------------------
;F1::
IfWinActive ahk_class ATL:00485158
run,e:\Docs\help\教程.boo
IfWinActive ahk_class ConsoleWindowClass
run,e:\Docs\help\vim.txt,e:\path\wm0.lnk
else
sendplay,F1
return
-------------------Ctrl+Win+f以今天日期建立文件夹----------------------
::^#l::
        ; 第一行增加快捷键
Click right
Send, wf
Sleep, 10
        ; 把暂停时间改小
clipboard = %A_YYYY%-%A_MM%-%A_DD%
        ; 增加上面这句,把当前的系统日期发送到剪贴板
Send, ^v{Enter}
        ; 发送 Ctrl + v 和回车
return
---------复制文字用记事本查看-----------
#s::
Send ^c
IfWinExist ahk_class Notepad2U
{
    WinActivate
}
else
{
    Run Notepad
    WinWait ahk_class Notepad2U
    WinActivate
}
Send ^a^v ;^a是为了替换可能在已打开的记事本中存在的文字,如果你只想跟随复制,那么去掉它即可
return
---------Eject DVD-----------
^#d::
    Drive, Eject
    If A_TimeSinceThisHotkey < 1000
        Drive, Eject, , 1
    Return 
---------Control Panel-----------
^#s::Run, Sysdm.cpl
^#e::Run, ncpa.cpl
^#i::Run, inetcpl.cpl
^#r::Run, regedit      ; Open the Windows Registry Editor.
::^#right::Run, control  ; Open Control Panel.
---------Volunm-----------
!Numpad0::Send, {VOLUME_MUTE}    
!NumpadSub::Send, {VOLUME_DOWN}  
!NumpadAdd::Send, {VOLUME_UP} 
---------Run Everything-----------   
#f::   
IfWinNotExist,ahk_class EVERYTHING   
Run,d:\path\et.lnk 
Else   
{   
    IfWinActive,ahk_class EVERYTHING   
 
       WinMinimize,   
 
    Else   
       WinActivate,   
}   
return
--------UI For 迅雷7----------   
^Numpad7:: 
DetectHiddenWindows, on
IfWinNotExist, 迅雷7
{
  run,f:\path\t7.lnk
  WinWait,迅雷7
  WinSet, Region, 195-60 W558 H225 R20-20
  WinMove,1305, 813 ;相对于屏幕左上角
 return
 }
else
{
Run, %comspec% /c taskkill /f /im  Thunder.exe&& taskkill /f /im ThunderPlatform.exe ;注意进程名区分大小写
return
}
--------UI For Run ----------   
;RWin::
IfWinNotExist, 运行
send #r    ;SendPlay有些键不能发送,如RWin
WinWait, 运行
WinSet, Transparent,190
WinSet, Style, -0xC00000    ;WS_CAPTION, 去掉title bar
WinSet, Region,68-86 W320 H16 R11-11
return
}
else
Winkill
return
------------置顶与否-----------

;^Up::WinSet,TopMost,,A ;按热键Ctrl+↑来切换激活的窗口的置顶与否的状态
return
---------填表范例----------- 

;#i::
r=我来凑热闹
clipboard = %r%
send,^v {tab}{tab}
send,ic...@qq.com {tab}
send, 13...3 {tab}{tab}
n=XNGNUEMC
clipboard = %n%
send,^v {tab}
a=河南....(南区)
clipboard = %a%
send,^v
return
----------------------------------------
::/d::
d = %A_YYYY%-%A_MM%-%A_DD%
        ;获得系统时间比如今天的时间:2007-10-21。如果需要“年”的话请替换上面的“-”。
clipboard = %d%
        ;把 d 的值发送到剪贴板,变量是不用声明的,想引用变量的值,就在变量的前后加“%”。第二行的变量是 AHK 自带的变量。
Send ^v
return
-----------------------------------------
!^r::
Reload   ; Reload the script by Alt+Ctrl+R.
ToolTip, 脚本已重启
-----------------------------------------


    Post a comment

    Your Name or E-mail ID (mandatory)

    Note: Your comment will be published after approval of the owner.

    No Attachments Found. Click here to upload new file.




     RSS of this page

    Written by:   Version:   Edited By:   Modified