What is AutoHotKey?
>AutoHotkey is a free, open-source custom scripting language for Microsoft Windows, initially aimed at providing easy keyboard shortcuts or hotkeys, fast macro-creation and software automation that allows users of most levels of computer skill to automate repetitive tasks in any Windows application.
>AutoHotkey scripts can be used to launch programs, open documents, send keystrokes and mouse clicks and movements. AutoHotkey scripts can also assign, retrieve, and manipulate variables, run loops and manipulate windows, files, and folders.
Purpose of /ahkg/
WE share and discuss scripts!
WINDOWS USERS ONLY. GANOO SLASH LOONIXFAGS NEED NOT APPLY. Don't come in here and derail this general saying how Windows is 'botnet' or how linux can do keyboard automation sooo much better
Menu, Tray, Icon, Shell32, 174
MouseGetPos, MouseX, MouseY
PixelGetColor, Colour, %MouseX%, %MouseY%, RGB
StringTrimLeft, Hex, Colour, 2
Clipboard := "#" . Hex
WinWait, Snipping Tool
WinActivate, Snipping Tool
Run, pythonw "D:\Software\_Utilities\PyUpload\upload.py" "%Clipboard%"
finally a thread on /g/ i could contribute to and i'm just here samefaggin
So, uh, how do you make a script which makes a tilde appear when I press the tilde key (left of one, below esc)? Sounds retarded, yes, but the thing is every time I press that key I get nothing and when I press it again I get ¸¸ (cedilla, U+00B8). That is without holding shift, and when I do hold shift and press it once I get nothing immediately again, but once more and I get ¨¨¨ (diaeresis, U+00A8). So, yeah, a script that clears what I presume is a character buffer and outputs ~ when I press the tilde key?
Anyone know how I can script the keyboard shortcuts of a semi-decent window manager? I only know how to set one position with one shortcut. What I don't know how to script is using the same shortcut to incrementally adjust a given window. For example I'd like
>start with maximized window
>Win-Left: window shrinks to left half of screen
>Win-Left: window shrinks horizontally again by half
>Win-Up: window shrinks vertically by half toward the top left corner
>Win-Right: window expands horizontally to half the screen width again without changing vertically
I know those commands, but the only way that comes to mind for me to use them is a bunch of conditionals. For example Win-Left could mean "halve the width of the active window and maintain its X position" if it's already on the left, or it could mean "double the width of the active window and adjust its X position" if it's on the right. That seems clunky as fuck.
Try using scancodes maybe. There's a script to find the scancode of a pressed key. Here's an example:SC159:: ; Replace 159 with your key's value.
MsgBox, %A_ThisHotKey% was pressed.
Thanks anon, using this:SC29::
It just werks now.