ProcessSetPriority "High"
SetMouseDelay -1
SendMode "InputThenPlay"
A_HotkeyInterval := 1000
A_MaxHotkeysPerInterval := 100
;--------------------------------------------------------
; Google日本語入力
;--------------------------------------------------------
; "C:\Program Files (x86)\Google\Google Japanese Input\GoogleIMEJaTool.exe" -mode=config_dialog
; キー設定の選択>編集
; sc07b 無変換
; Muhenkan > IMEを無効化
; Shift Muhenkan > IMEを無効化
; sc070 ひらがな
; Hiragana > IMEを有効化
; sc079 変換
; Henkan > エントリー削除
; Shift Henkan > エントリー削除
;--------------------------------------------------------
; Esc(RShift)※左1段目
;--------------------------------------------------------
>+MButton::Send "#{Tab}"
>+WheelUp::Send "{PgUp}"
>+WheelDown::Send "{PgDn}"
>+h::Send "{Left}"
>+j::Send "{Down}"
>+k::Send "{Up}"
>+l::Send "{Right}"
>+7::Send "{Home}"
>+8::Send "{End}"
>+q::Send "{&}"
>+w::Send "{'}"
>+e::Send "{``}"
>+a::Send "{^}"
>+s::Send "{$}"
>+d::Send "{~}"
>+u::Send "{|}"
>+i::Send "{\}"
>+o::Send "{@}"
>+p::Send "{`%}"
>+n::Send "{(}"
>+m::Send "{)}"
>+4::Send "{Enter}"
>+Enter::Send "{Tab}"
>+Backspace::Send "{Delete}"
;--------------------------------------------------------
; Tab(変換)※左2段目
;--------------------------------------------------------
sc079 & 1::Send "{F12}"
sc079 & 2::Send "{F2}"
sc079 & q::Send "{Esc}"
sc079 & w::Send "{LWin}"
sc079 & e::Send "#e"
sc079 & r::Send "#r"
sc079 & c::Send "#c" ; Color Picker
; 移動+Shift
sc079 & h::Send "+{Left}"
sc079 & j::Send "+{Down}"
sc079 & k::Send "+{Up}"
sc079 & l::Send "+{Right}"
sc079 & 7::Send "+{Home}"
sc079 & 8::Send "+{End}"
;--------------------------------------------------------
; LControl
;--------------------------------------------------------
~<^c::
{
If (A_PriorHotkey = A_ThisHotkey && 500 > A_TimeSincePriorHotkey)
{
Send "{End}+{Home}^c"
}
}
;--------------------------------------------------------
; LAlt
;--------------------------------------------------------
; エクセル以外単独押下無効
~LAlt::
{
if (WinActive("ahk_exe excel.exe") = 0)
{
Send "{vk99}"
}
}
<!1::Send "{Home}"
<!2::Send "{End}"
<!q::Send "!{Left}" ; 戻る
<!w::Send "!{Right}" ; 進む
<!e::Send "^w" ; 閉じる
<!a::Send "^{PgUp}" ; 前のタブ
<!s::Send "^{PgDn}" ; 次のタブ
<!d::Send "^+t" ; 再び開く
<!f::Send "^{F5}" ; 更新
<!z::Send "!+{Z}" ; Chrome拡張(右側のタブを閉じる)
CoordMode "Mouse", "Window"
<!v::
{
static keyDownCount
If (A_PriorHotkey = A_ThisHotkey && 500 > A_TimeSincePriorHotkey)
{
keyDownCount += 1
If (keyDownCount > 1)
{
keyDownCount := 0
}
}
Else
{
keyDownCount := 0
}
this_id := WinGetID("A")
If (WinGetMinMax(this_id) = 1)
{
WinRestore(this_id)
WinMove(,,1100,750,this_id)
}
WinGetPos(&x, &y, &w, &h, this_id)
If (keyDownCount = 0)
{
MouseMove(w//2, 8)
}
Else If (keyDownCount = 1)
{
MouseMove(w-5, h-5)
}
}
;--------------------------------------------------------
; 無変換(Space左側)
;--------------------------------------------------------
~sc07b::
{
If (A_PriorHotkey = A_ThisHotkey && 500 > A_TimeSincePriorHotkey)
{
Send "{sc070}"
}
}
;--------------------------------------------------------
; マウス
;--------------------------------------------------------
F14::
{
if (WinActive("ahk_exe chrome.exe") != 0)
{
Send "!+e" ; Chrome拡張(ESET)
}
for this_id in WinGetList("ahk_exe chrome.exe")
{
If (WinExist(this_id) != 0 && WinGetMinMax(this_id) = 0)
{
WinClose(this_id)
}
}
}