#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases. ; #Warn ; Enable warnings to assist with detecting common errors. SendMode Input ; Recommended for new scripts due to its superior speed and reliability. SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory. ^Left:: Send {Home} Return ^Right:: Send {End} Return ^+Left:: Send +{Home} Return ^+Right:: Send +{End} Return ^Up:: Send ^{Home} Return ^Down:: Send ^{End} Return ^+Up:: Send ^+{Home} Return ^+Down:: Send ^+{End} Return *tab:: { if (GetKeyState("LAlt", "P")) { Send {LControl up}{Alt down}{tab} KeyWait, tab } else if (GetKeyState("LShift", "P")) { Send {LShift down}{tab} KeyWait, tab } else if (GetKeyState("LControl", "P")) { Send {LControl down}{Alt up}{tab} KeyWait, tab } else { send {tab} } return } ~LAlt Up:: { send {lalt up} return } LAlt::LCtrl LCtrl::LAlt