Skip to content

Instantly share code, notes, and snippets.

@tinku99
Created April 15, 2012 22:43
Show Gist options
  • Save tinku99/2395177 to your computer and use it in GitHub Desktop.
Save tinku99/2395177 to your computer and use it in GitHub Desktop.
mouse with the keyboard
CustomColor = 000000
Gui +LastFound +AlwaysOnTop -Caption +ToolWindow ; +ToolWindow avoids a taskbar button and an alt-tab menu item.
Gui, Color, %CustomColor%
Gui, Font, s10 cwhite
yb := A_ScreenHeight - 40
xb := A_ScreenWidth - 40
loop, 26{
char := chr(Asc("A") + A_Index - 1)
x := floor(A_ScreenWidth * (1 - ((asc("Z") - asc(char) + 1) / 26)) )
loop, 26{
ychar := chr(Asc("A") + A_Index - 1)
y := floor(A_ScreenHeight * (1 - ((asc("Z") - asc(ychar) + 1) / 26)) )
Gui, add, text, X%x% Y%y%, %char% %ychar%
}
}
WinSet, TransColor, %CustomColor% 200
return
!r::reload
!m::
Gui, Show, X0 Y0 W%A_ScreenWidth%
Input, xy, L2, {LControl}{RControl}{LAlt}{RAlt}{LShift}{RShift}{LWin}{RWin}{AppsKey}{F1}{F2}{F3}{F4}{F5}{F6}{F7}{F8}{F9}{F10}{F11}{F12}{Left}{Right}{Up}{Down}{Home}{End}{PgUp}{PgDn}{Del}{Ins}{BS}{Capslock}
xchar := SubStr(xy, 1, 1)
ychar := SubStr(xy, 2, 1)
xzchar := substr(xy, 3, 1)
yzchar := substr(xy, 4, 1)
/*
xa := ya := 0
if (xzchar = "f")
xa := 10
if (xzchar = "j")
xa := 20
if (yzchar = "f")
ya := 10
if (yzchar = "j")
ya := 20
*/
x := A_ScreenWidth * (1 - ((asc("z") - asc(xchar) + 1) / 26))
y := A_ScreenHeight * (1 - ((asc("z") - asc(ychar) + 1) / 26))
coordmode, mouse, screen
MouseMove, % x, % y
Gui, Hide
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment