Created
March 22, 2020 11:20
-
-
Save kdankov/b7b2795634d4d0c4f703458a44783ce3 to your computer and use it in GitHub Desktop.
Windows Keyboard Mapping Fixes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#SingleInstance force | |
/* | |
#InstallKeybdHook | |
$VKE2::Send, {``} | |
$+VKE2::Send, {~} | |
$VKC0::Send, {\} | |
$+VKC0::Send, {|} | |
Top Left Tilde Codes | |
VKC0 | |
SC029 | |
Bottom Left Tilde Codes | |
VKE2 | |
SC056 | |
Ю | |
ю | |
Ч | |
ч | |
*/ | |
LAlt & VKC0::Send, {Alt Down}{Shift Down}{Shift Up}{Alt Up} | |
$VKE2:: | |
LangID := % DllCall("GetKeyboardLayout", Int,DllCall("GetWindowThreadProcessId", int,WinActive("A"), Int,0)) | |
if ( LangID = -256965630 ) | |
{ | |
Send, {ч} | |
} | |
else if ( LangID = 67699721 ) | |
{ | |
Send, {``} | |
} | |
else | |
{ | |
MsgBox % LangID | |
} | |
return | |
$+VKE2:: | |
LangID := % DllCall("GetKeyboardLayout", Int,DllCall("GetWindowThreadProcessId", int,WinActive("A"), Int,0)) | |
if ( LangID = -256965630 ) | |
{ | |
Send, {Ч} | |
} | |
else if ( LangID = 67699721 ) | |
{ | |
Send, {~} | |
} | |
else | |
{ | |
MsgBox % LangID | |
} | |
return | |
$VKC0:: | |
LangID := % DllCall("GetKeyboardLayout", Int,DllCall("GetWindowThreadProcessId", int,WinActive("A"), Int,0)) | |
if ( LangID = -256965630 ) | |
{ | |
Send, {ю} | |
} | |
else if ( LangID = 67699721 ) | |
{ | |
Send, {\} | |
} | |
else | |
{ | |
MsgBox % LangID | |
} | |
return | |
$+VKC0:: | |
LangID := % DllCall("GetKeyboardLayout", Int,DllCall("GetWindowThreadProcessId", int,WinActive("A"), Int,0)) | |
if ( LangID = -256965630 ) | |
{ | |
Send, {Ю} | |
} | |
else if ( LangID = 67699721 ) | |
{ | |
Send, {|} | |
} | |
else | |
{ | |
MsgBox % LangID | |
} | |
return |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment