Copyright © 2013-2018
add description for all functions
Fixed conflict for
Move mouse 1px
. The HotKeyAlt-Win-ARROW
was already used byStretch to edge
. The new HotKey for moving the mouse is Alt + Shift + Win.
Merged Quick Resolution
into the Resize window
menu. which key was used by QR???
major bug fixed in hotString() which was preventing creating HotKeys for single keys (like F1-F12, etc). some single keys still cannot have a standalone HotKey defined (list them!)
This version changes existing functionality of HotScript, mostly around HotKeys that were specific to HotScript itself.
Please read the change history for this version carefully to understand how these changes affect your usage of HotScript.
Because of the quanity of changes/fixes/etc., they are not listed in any particular order. After 15+ months of development on this version, there are approximately 650 separate modifications (including ?? new features) to the source code!
This release will likely be the last substantial version for quite sometime. There will still be releases for any bugs, but don't expect any new major functionality.
I have started work on the next generation of HotScript, which will deliver greater flexibility, simpler ease of use, enhanced capabilities, and some long-awaited features.
Added HotKey Alt + Win + R which shows a
Resize window
menu. All window resizing functions are available via this new menu. This purpose for this new menu is to help people who found it difficult to remember which HotKeys are associated with the various window resizing options of HotScript.
Added new HotKeys to shift a window up/down/left/right. The default number of pixels is defined in
HotScriptDefault.ini
with theshiftWindowPixels
variable and is set to 50 pixels. This value may be copied intoHotScriptUser.ini
and set to any other integer value greater than zero. The new HotKeys are:
- Shift + WheelDown - Shift the current window down 50 pixels
- Shift + WheelUp - Shift the current window down 50 pixels
- Alt + Shift + WheelUp - Shift the current window left 50 pixels
- Alt + Shift + WheelDown - Shift the current window right 50 pixels
Changed the "Resize to grid" HotKeys that used the
NumPad
number keys to no longer be specific to just theNumPad
. Now any HotKey that uses a number for window resizing can use either theNumPad
or the traditional number keys. This was done because some keyboard (such as laptops) do not have aNumPad
available. As a result, the following new HotKeys are defined:
- Win + 1 - Same as Win + NumPad1
- Win + 2 - Same as Win + NumPad2
- Win + 3 - Same as Win + NumPad3
- Win + 4 - Same as Win + NumPad4
- Win + 5 - Same as Win + NumPad5
- Win + 6 - Same as Win + NumPad6
- Win + 7 - Same as Win + NumPad7
- Win + 8 - Same as Win + NumPad8
- Win + 9 - Same as Win + NumPad9
All other HotKeys that used
NumPad
for resizing have been eliminated and are available on theResize window
menu.
This is a significant change to existing functionality of HotScript.
Changed meaning of HotKey Win + F12. It used to quit HotScript, but now it displays the HotScript menu. The feature for quitting HotScript is now on the HotScript menu.
Changed behavior of Win + H to be both a toggle as well as retaining its existing behavior. Pressing it once will now toggle the help screen on and off. Pressing and holding the keys will work as they did before - when released the help screen will be hidden.
Functionality for several HotKeys has been moved to the new HotScript menu accessible via Win + F12. The following HotKeys were removed:
- Win + 1 for running AutoHotkey help file
- Win + 2 for reloading HotScript
- Win + 3 for editing
HotScript.ahk
- Win + 4 for editing
HotScriptKeys.ahk
- Win + 5 for editing
HotScriptStrings.ahk
- Win + 6 for editing
HotScriptVariables.ahk
- Win + 7 for editing
HotScriptFunctions.ahk
- Win + 8 for editing
HotScriptUser.ini
- Win + 9 for editing
HotScriptDefault.ini
- Win + 0 for launching the HotScript home page in the default browser
- Win + ` for launching DebugView (used for debugging HotScript)
- Alt + Win + F12 for running a HotScript internal function
- Ctrl + Win + F12 for viewing the value of a HotScript internal variable
- Alt + Win + H for running Windows Explorer in the HotScript folder
- Ctrl + Win + H would toggle the help screen on and off. This feature has not combined with the existing Win + H HotKey and is not available with the HotScript menu.
Functionality for several HotKeys has been moved to the new
Resize window
menu accessible via Alt + Win + R. The following HotKeys were removed:
- Ctrl + Win + NumPad0
- Ctrl + Win + NumPadInsert
- Ctrl + Win + NumPad4
- Ctrl + Win + NumPadLeft
- Ctrl + Win + NumPad7
- Ctrl + Win + NumPadHome
- Alt + Win + NumPad1
- Alt + Win + NumPadEnd
- Alt + Win + NumPad2
- Alt + Win + NumPadDown
- Alt + Win + NumPad4
- Alt + Win + NumPadLeft
- Alt + Win + NumPad5
- Alt + Win + NumPadClear
- Alt + Win + NumPad7
- Alt + Win + NumPadHome
- Alt + Win + NumPad8
- Alt + Win + NumPadUp
- Ctrl + Win + NumPad1
- Ctrl + Win + NumPadEnd
- Ctrl + Win + NumPad2
- Ctrl + Win + NumPadDown
- Ctrl + Win + NumPad3
- Ctrl + Win + NumPadPgDn
- Ctrl + Win + NumPad4
- Ctrl + Win + NumPadLeft
- Ctrl + Win + NumPad5
- Ctrl + Win + NumPadClear
- Ctrl + Win + NumPad6
- Ctrl + Win + NumPadRight
- Win + F1
- Win + F2
- Win + F3
- Win + F4
- Alt + Win + F1
- Alt + Win + F2
- Alt + Win + F3
- Alt + Win + F4
- Ctrl + Win + F1
- Ctrl + Win + F2
- Ctrl + Win + F3
- Ctrl + Win + F4
- Shift + Win + F1
- Shift + Win + F2
- Shift + Win + F3
- Shift + Win + F4
- Win + F5
- Win + F6
- Win + F7
- Win + F8
- Alt + Win + F5
- Alt + Win + F6
- Alt + Win + F7
- Alt + Win + F8
- Ctrl + Win + F5
- Ctrl + Win + F6
- Ctrl + Win + F7
- Ctrl + Win + F8
- Shift + Win + F5
- Shift + Win + F6
- Shift + Win + F7
- Shift + Win + F8
- Win + F9
- Win + F10
- Win + F11
- Alt + Win + F9
- Alt + Win + F10
- Alt + Win + F11
- Ctrl + Win + F9
- Ctrl + Win + F10
- Ctrl + Win + F11
- Ctrl + Win + F12
- Shift + Win + F10
- Shift + Win + F11
- Shift + Win + F12
Fixed an issue when pasting text containing line ending into a DOS windows there would be extra blank lines in between.
Added HotString
@+-
to generate the plus-minus sign±
character.
Added the following functions:
checkVersionsForce
-findWindow
-hkHotScriptHomePage()
- Launches the HotScript homepage in the default browserhkHotScriptMenu()
- Displays the HotScript menuhkWindowShiftWindowDown()
-hkWindowShiftWindowLeft()
-hkWindowShiftWindowRight()
-hkWindowShiftWindowUp()
-isActive()
-getMenuColor()
-getMenuColorName()
-moveMouseForMonitor()
-resizeTo1x2_01()
resizeTo1x2_02()
resizeTo1x3_01()
resizeTo1x3_02()
resizeTo1x3_03()
resizeTo1x4_01()
resizeTo1x4_02()
resizeTo1x4_03()
resizeTo1x4_04()
resizeTo2x1_01()
resizeTo2x1_02()
resizeTo2x2_01()
resizeTo2x2_02()
resizeTo2x2_03()
resizeTo2x2_04()
resizeTo2x3_01()
resizeTo2x3_02()
resizeTo2x3_03()
resizeTo2x3_04()
resizeTo2x3_05()
resizeTo2x3_06()
resizeTo2x4_01()
resizeTo2x4_02()
resizeTo2x4_03()
resizeTo2x4_04()
resizeTo2x4_05()
resizeTo2x4_06()
resizeTo2x4_07()
resizeTo2x4_08()
resizeTo3x1_01()
resizeTo3x1_02()
resizeTo3x1_03()
resizeTo3x2_01()
resizeTo3x2_02()
resizeTo3x2_03()
resizeTo3x2_04()
resizeTo3x2_05()
resizeTo3x2_06()
resizeTo3x3_01()
resizeTo3x3_02()
resizeTo3x3_03()
resizeTo3x3_04()
resizeTo3x3_05()
resizeTo3x3_06()
resizeTo3x3_07()
resizeTo3x3_08()
resizeTo3x3_09()
resizeTo3x4_01()
resizeTo3x4_02()
resizeTo3x4_03()
resizeTo3x4_04()
resizeTo3x4_05()
resizeTo3x4_06()
resizeTo3x4_07()
resizeTo3x4_08()
resizeTo3x4_09()
resizeTo3x4_10()
resizeTo3x4_11()
resizeTo3x4_12()
resizeTo4x1_01()
resizeTo4x1_02()
resizeTo4x1_03()
resizeTo4x1_04()
resizeTo4x2_01()
resizeTo4x2_02()
resizeTo4x2_03()
resizeTo4x2_04()
resizeTo4x2_05()
resizeTo4x2_06()
resizeTo4x2_07()
resizeTo4x2_08()
resizeTo4x3_01()
resizeTo4x3_02()
resizeTo4x3_03()
resizeTo4x3_04()
resizeTo4x3_05()
resizeTo4x3_06()
resizeTo4x3_07()
resizeTo4x3_08()
resizeTo4x3_09()
resizeTo4x3_10()
resizeTo4x3_11()
resizeTo4x3_12()
resizeTo4x4_01()
resizeTo4x4_02()
resizeTo4x4_03()
resizeTo4x4_04()
resizeTo4x4_05()
resizeTo4x4_06()
resizeTo4x4_07()
resizeTo4x4_08()
resizeTo4x4_09()
resizeTo4x4_10()
resizeTo4x4_11()
resizeTo4x4_12()
resizeTo4x4_13()
resizeTo4x4_14()
resizeTo4x4_15()
resizeTo4x4_16()
resizeToHeight()
resizeToWidth()
runChat()
runForum()
runHistory()
runHotScriptFolder()
runWindowSpy()
selfSuspend()
shiftWindow()
-
Added a parameter to
centerMouse()
to disable the small mouse animation the occurs after centering the mouse.
Changed
showQuickHelp()
to toggle on and off when Win + H is pressed as well as to only display the help screen while the keys are pressed, then hiding the help screen when the keys are released.
Changed
runDos()
to better filter out windows that mimicConsoleWindowClass
which will prevent activating currently running DOS windows that are not active.
Changed several functions to no longer be affected by the change made in version 1.20170813.1 that added a 250ms delay for window operations. These caused unnecessary slowness and these functions did not need the delay:
centerWindow()
extractLocationAndResize()
moveToEdge()
moveToMonitor()
moveToNextPrevMonitor()
resizeWindow()
stretchToEdge()
Changed
extractLocationAndResize()
to move a window instead of resizing it if ScrollLock is turned on. This effects all of the "resize to grid" HotKeys as well as the applicable entries within theResize window
menu.
Improved reliability of
isActiveDos()
to filter out hidden windows. This is seen by some applications like the DellApntex.exe
and Intelesrv.exe
applications that register themselves asConsoleWindowClass
.
Added the position values of a window to the information returned by
showWindowInfo()
. Now the values totop
,bottom
,left
, andright
will be displayed.
The dialog window displayed by
showWindowInfo()
will no longer have the minimize or maximize buttons on it.
Changed
selfReload()
to be more selective about silently reloading. This should only occur when the parameter is actuallyfalse
instead of just being present.
Renamed
moveWindow()
tomoveWindowNextPrevMonitor()
so that its meaning is more clear.
Changed the HotScript tray menu color to be the same as the other menu colors (FFFFDD).
Changed
hkWindowResizeToAnchor()
to no longer try to handle resizing a window to max height or max width. The reliability of it was not at the level I would expect. This is now available via theResize window
menu HotKey Ctrl + Win + R.
Changed
menuBuilder()
to no longer add a separator line and&Cancel
menu entries to every menu. If you want these, you will need to add them.
Changed
menuBuilder()
to inheritmenuHandler
options. With this change, you can specify a top-level handler, then further down within a menu a newhandler
can be specified where all entries below it that do not have their own handler will use the closest one specified to it.
Changed
menuBuilder()
to allow menu entries to be more than simple text. It is now possible to define a sub-menu or menu entry to have its own icon. Sub-menus can now override the default (built-in) color. A handler can be defined for each menu entry instead of relying on a shared/generic handler. Menu entries can also be disabled at the time of definition. All of these new options are being used by the newResize window
menu via the HotKey Alt + Win + R. To explore the possibilities for your own menus, refer to thehkWindowResizeWindowMenu()
function.
Removed the options for
runIcon
andwarnIcon
withinmenuBuilder()
. With the new functionality of being able to specify a custom icon and handler per entry, this no longer has as much meaning as it once did.
Due to many HotKeys having been removed in this version, the following functions are no longer needed and have been removed:
hkHotScriptAutoHotkeyHelp()
hkHotScriptExit()
hkHotScriptHome()
hkHotScriptFolder()
hkHotScriptQuickHelp()
hkHotScriptQuickHelpToggle()
hkHotScriptReload()
hkWindowResize()
hkWindowResizeTo1x2_01()
hkWindowResizeTo1x2_02()
hkWindowResizeTo1x3_01()
hkWindowResizeTo1x3_02()
hkWindowResizeTo1x3_03()
hkWindowResizeTo1x4_01()
hkWindowResizeTo1x4_02()
hkWindowResizeTo1x4_03()
hkWindowResizeTo1x4_04()
hkWindowResizeTo2x1_01()
hkWindowResizeTo2x1_02()
hkWindowResizeTo2x2_01()
hkWindowResizeTo2x2_02()
hkWindowResizeTo2x2_03()
hkWindowResizeTo2x2_04()
hkWindowResizeTo2x3_01()
hkWindowResizeTo2x3_02()
hkWindowResizeTo2x3_03()
hkWindowResizeTo2x3_04()
hkWindowResizeTo2x3_05()
hkWindowResizeTo2x3_06()
hkWindowResizeTo2x4_01()
hkWindowResizeTo2x4_02()
hkWindowResizeTo2x4_03()
hkWindowResizeTo2x4_04()
hkWindowResizeTo2x4_05()
hkWindowResizeTo2x4_06()
hkWindowResizeTo2x4_07()
hkWindowResizeTo2x4_08()
hkWindowResizeTo3x1_01()
hkWindowResizeTo3x1_02()
hkWindowResizeTo3x1_03()
hkWindowResizeTo3x2_01()
hkWindowResizeTo3x2_02()
hkWindowResizeTo3x2_03()
hkWindowResizeTo3x2_04()
hkWindowResizeTo3x2_05()
hkWindowResizeTo3x2_06()
hkWindowResizeTo3x4_01()
hkWindowResizeTo3x4_02()
hkWindowResizeTo3x4_03()
hkWindowResizeTo3x4_04()
hkWindowResizeTo3x4_05()
hkWindowResizeTo3x4_06()
hkWindowResizeTo3x4_07()
hkWindowResizeTo3x4_08()
hkWindowResizeTo3x4_09()
hkWindowResizeTo3x4_10()
hkWindowResizeTo3x4_11()
hkWindowResizeTo3x4_12()
hkWindowResizeTo4x1_01()
hkWindowResizeTo4x1_02()
hkWindowResizeTo4x1_03()
hkWindowResizeTo4x1_04()
hkWindowResizeTo4x2_01()
hkWindowResizeTo4x2_02()
hkWindowResizeTo4x2_03()
hkWindowResizeTo4x2_04()
hkWindowResizeTo4x2_05()
hkWindowResizeTo4x2_06()
hkWindowResizeTo4x2_07()
hkWindowResizeTo4x2_08()
hkWindowResizeTo4x3_01()
hkWindowResizeTo4x3_02()
hkWindowResizeTo4x3_03()
hkWindowResizeTo4x3_04()
hkWindowResizeTo4x3_05()
hkWindowResizeTo4x3_06()
hkWindowResizeTo4x3_07()
hkWindowResizeTo4x3_08()
hkWindowResizeTo4x3_09()
hkWindowResizeTo4x3_10()
hkWindowResizeTo4x3_11()
hkWindowResizeTo4x3_12()
hkWindowResizeTo4x4_01()
hkWindowResizeTo4x4_02()
hkWindowResizeTo4x4_03()
hkWindowResizeTo4x4_04()
hkWindowResizeTo4x4_05()
hkWindowResizeTo4x4_06()
hkWindowResizeTo4x4_07()
hkWindowResizeTo4x4_08()
hkWindowResizeTo4x4_09()
hkWindowResizeTo4x4_10()
hkWindowResizeTo4x4_11()
hkWindowResizeTo4x4_12()
hkWindowResizeTo4x4_13()
hkWindowResizeTo4x4_14()
hkWindowResizeTo4x4_15()
hkWindowResizeTo4x4_16()
hkWindowResizeToHeight()
hkWindowResizeToWidth()
runQuickResolution()
Fixed issue with
menuBuilder
where it would not properly destroy sub-menus once the menu was closed. This could be seen if a sub-menu has separator lines in it. Each subsequent time a menu would be displayed, the number of separator lines a sub-menu would be increased.
Removed some debug information from
repeatStr()
where it would be displayed if the number of times to repeat was greater than 500.
Minor adjustment (for consistency) in the names of keys used for HotKey definitions. This should have no impact on functionality.
With the removal of several HotKeys specific to HotScript, this resulted in a minor redesign of the help screen.
Fixed the URL to the change log file (this file).
Added HotKey Win + Esc to toggle the Windows Desktop. If no applications have been launched or activated while viewing the Desktop, pressing the HotKey again will restore all windows to their previous state.
Added HotKey Win + U to convert the highlighted text or the text contents from the Windows Clipboard into a shortened URL. The original text must be a valid URL. If no matching text is selected or on the Window Clipboard, a dialog will be displayed prompting for the input. Once the shortened URL has been generated, a dialog will display showing the original URL and the shortened URL (as clickable links). There is a button to copy the shortened URL to the Windows Clipboard.
Added DOS mouse HotKey Back button to move up one directory level. It is the same as the existing HotKeys of Alt + Up and Alt + . but accessible via a mouse button.
Added DOS HotKey Ctrl + . to run Explorer for the current folder.
Changed the output of DOS HotKey Alt + R from
cd\
tocd \
.
Removed two entries (
Jira
andConfluence
) from Quick Lookup Win + Q that were not applicable to most users.
Fixed Back and Forward mouse buttons not working as they used to in EditPad Pro. This was caused by the new mouse HotKeys added in 1.20170425.1. This is a temporary fix that uses an aggregate function to check for various active windows and executing the correct action. The long-term solution is to add support for multiple HotKeys to share the key(s) but yet have different conditions upon which they will be triggered. For now, this solution will suffice.
The ending character after typing a fraction is now preserved.
Some ending characters, specifically
! # ^ + { }
, were not being rendered for several built-in HotStrings. This was caused by a change from version 1.20170626.1.
Added several global variables for use with Windows API calls:
WM_COMMAND
WM_HSCROLL
WM_VSCROLL
WS_CHILD
WS_DISABLED
WS_EX_APPWINDOW
WS_EX_CONTROLPARENT
WS_EX_TOOLWINDOW
WS_POPUP
WS_VISIBLE
Added the following functions:
addQuickLookup()
- Adds a new action to the HotKey Win + Q for Quick LookupgetEndChar()
- returns the last character typed that triggered a HotStringisActiveRdp()
- returnstrue
if the active window is Windows Remote Desktop, otherwisefalse
isActiveSsh()
- returnstrue
if the active window is an SSH DOS-like client (currently Putty and Kitty), otherwisefalse
isWin10()
- returnstrue
if the operating system is Windows 10, otherwisefalse
shortenUrl()
- returns a shortened URL for the specified text
Changed
hotString()
to capture the last character typed (in the same way asA_EndChar
). It is accessible by callinggetEndChar()
or in the variablehs.vars.endChar
.
Changed
hotString()
to be smarter about how to render HotStrings. With the change tohotString()
made in version 1.20170626.1, the new method simulated typing each character which allowed for embedding keystrokes within the text, but this was much slower. In versions previous to 1.20170626.1, all text was pasted and was much faster, but did not allow keystrokes to be embedded. Now, HotScript will decide which method to use depending upon the contents of the string to be rendered. For strings that do not have embedded keystrokes, the faster paste method will be used. When keystrokes are embedded, the slower method must be used, but this typically is only used for shorter strings anyway. Strings starting with{RAW}
will use the paste method after removing the{RAW}
prefix.
Improved handling within
getSelectedText()
for DOS windows. Any selected text within the DOS window should be properly detected and returned, whereas this was previously ignored for all DOS windows. This makes it far easier to select a path or some text and use the Win + G HotKey.
Removed some unnecessary code and variables from
ask()
.
Reverted change to
ClipWait()
from version 1.20170614.1, so it now uses a 0.1 second delay. Certain HotKeys and HotStrings were taking too long to execute with 2 seconds.
Removed a small (unnecessary) wait within
pasteText()
.
Changed
pasteText()
to allow it to paste text within SSH apps.
Fixed an issue in
hkMiscCenterMouseWindow()
when triggered within an RDP session and HotScript was running both locally and remotely. The function would get executed first remotely then locally, causing the cursor to be centered on the screen instead of the window. The fix is to detect if the local window is an RDP session and also maximized. If so, then no action is run on the local instance, allowing the remote instance to properly handle moving the cursor to be centered within the remote window.
Fixed issue with
pasteText()
not working for SSH applications like Putty.
Added window group for SSH apps (SshGroup). Currently only Putty and Kitty are defined.
Added window group for Remote Desktop apps (RdpGroup). Currently only Microsoft Remote Desktop is defined.
Changed the delay for window functions from 0ms to 250ms. This should help with some applications not getting focused when launched via HotKey or with focusing application windows in general.
Moved some definitions for Windows API calls from being local variables to global.
Changed all Windows API calls from
SendMessage
toPostMessage
.
Renamed
changes.txt
tochanges.md
(this file).
Refactored the historical changes (this file) to be more visually readable when viewed through GitHub.
With the change to hotString()
made in version 1.20170626.1, for simple text replacement strings, be aware that the following characters are treated as being special: ! # ^ + { }
If any of these characters appear anywhere within the string, they will not be included in the output by default. There are a few ways to control how these characters will be handled. Below are a few examples:
hotString("test1", "a+bc{left}d!#^{}") hotString("test2", "{raw}a+bc{left}d!#^{}") hotString("test3", "a+bc{left}d{!}{#}{^}{{}{}}")
test1
will act upon and interpret special characters. The output would be:aBdc
test2
will treat the string literally because it starts with{raw}
. The output would be:a+bc{left}d!#^{}
test3
allows for both interpretation and literal strings. The output would be:aBd!#^{}c
To allow for both interpretation as well as literal strings, any of the special characters must be escaped by surrounding that character with open and close curly brackets
{}
, even the open or close curly brackets themselves. For example:{!} {#} {^} {+} {{} {}}
Added HotKeys to resize (stretch) a window to an edge of the monitor. This greatly adds to the customizable nature of resizing to a grid. With this new feature, it is possible to move a window somewhere within the grid and then resize it in one direction taking up the remainder of the height or width.
- Alt + Win + Up - Expand the current window to the top edge of the screen
- Alt + Win + Left - Expand the current window to the left edge of the screen
- Alt + Win + Right - Expand the current window to the right edge of the screen
- Alt + Win + Down - Expand the current window to the bottom edge of the screen
When using Quick Resolution (Ctrl + Win + R), width and height values are now saved/populated when invoking it again. This allows for easily changing just one of the previously entered values without needing to enter both. The saved value is only during run-time. If HotScript is reloaded, the values will not be retained.
Modified
getWindowInfo()
to no longer require anhWnd
parameter. It will now default to the active window if no parameter is specified.
Minor changes for Windows 10 adjustments when resizing windows into a grid or to an edge. If the Windows taskbar is at the bottom (the default), then moving a window to the bottom of the monitor would cause the resize area for that window to be inaccessible.
Fixed issue with not properly saving/restoring the
CoordModeMouse
value.
Minor code cleanup for consistency.
Added DOS HotString
rd
which will append/s
.
Modified
hotKeyAction()
to be able to support AutoHotkey-style named keys. This allowshotString()
definitions to also use the named keys. An example is:hotString("@test", "Line 1{Enter 2}Line 3{Enter 2}Line{Tab 4}5{Enter}")
Added the following functions:
showWindow()
- makes a window visible that was previously hiddensortByValue()
- sorts an object or associative array by its values rather than by its keys
If the specified window cannot be found,
showWindowInfo()
will no longer display a dialog, because it just contained blank values anyway, which is not helpful.
Increased the timeout of
ClipWait()
to 2 seconds. This may help with some computers having issues with copy/paste functions.
Changed
Run()
to wait (up to 2 seconds) for the program to become active before returning.
Modified
arrangeToGrid()
to take an additional parameter to indicate if windows should be sorted alphabetically by the window title.
Modified
arrangeToGrid()
to allow for the first parameter (winMatch
) to be an array containinghWnd
values or an object containing window title(s) as a key andhWnd
value(s) to be assigned to each key. This allows for passing in already knownhWnd
values. One use for this could be writing a custom function to launch several applications, saving thehWnd
values into an array and passing them intoarrangeToGrid()
.
As part of the
DosGroup
, any window created by Dell'sApntex.exe
will now be ignored. This application identifies itself as aConsoleWindowClass
which should be restricted to DOS-like windows. It was causing things like the Win + D HotKey needing to be pressed twice, so now it is ignored.
Minor code cleanup for consistency.
Added the following functions:
arrangeToGrid()
- arranges windows to a gridmoveToMonitor()
- moves a window to the specified monitor
Renamed
moveToMonitor()
tomoveWindow()
.
Added an additional parameter to
pad()
to allow the padding character to be specified.
Minor code cleanup for consistency.
To use arrangeToGrid()
function, a HotKey will need to be created. This function takes three parameters: winMatch
, dimension
and sortByTitle
winMatch
is any legal syntax for "WinTitle". See the AutoHotkey help for WinTitle. HotScript uses the "RegEx" mode of searching for WinTitle values.
dimension
is in the format ofCxR
(Columns and Rows) with a minimum of 1 and maximum of 4 Any value less than 1 will be set to 1. Any value greater than 4 will be set to 4. Any values not conforming to the format ofCxR
will result in an exception being thrown.
sortByTitle
is optional and defaults totrue
. Whentrue
, any windows found will be arranged by according to how each of their titles would be sorted (ascending only). Whenfalse
, any windows found will be arranged according to the z-order of each window. The z-order may be influenced by clicking on each of the windows to be arranged in the reverse order of how you would like them to be arranged. This is because the last window touched is the first to be acted upon.Typically, this function would be used to arrange a group of similar windows, such as Notepad. Below is some sample code that would arrange all instance of Notepad in a 3x2 grid across all monitors, if necessary.
First, define a HotKey (put this in
HotScriptKeys.ahk
):hotKey("^#n", "arrangeNotepad")Next, create the function (put this in
HotScriptFunctions.ahk
):arrangeNotepad() { arrangeToGrid("ahk_exe i)Notepad.exe", "3x2") }
arrangeToGrid()
will start arranging windows on the first monitor. If more windows are found than will fit the specified grid, if other monitors are attached, they will also be used. If the number of windows found exceeds all available grid positions for all monitors, the remaining windows will not be moved/resized and will remain exactly as they were.The placement of the windows within the grid will be from top-to-bottom and left-to-right, starting with the monitor that Windows identifies as being the primary.
Added the following HotKeys for DOS:
- Ctrl + Down - Scroll the screen down one line
- Ctrl + Up - Scroll the screen up one line
Moved the following HotKeys out of the "Action Keys" section:
- Win + A (Toggle always-on-top) to the "Window Keys" section
- Ctrl + Win + A (Toggle click-through) to the "Window Keys" section
- Alt + Apps (Toggle desktop icons) to the "Miscellaneous Keys" section
Removed the following HotKeys for DOS (these were duplicates of Ctrl + PgUp and Ctrl + PgDn):
- Alt + PgDn (Scroll down one page)
- Shift + PgDn (Scroll down one page)
- Alt + PgUp (Scroll up one page)
- Shift + PgUp (Scroll up one page)
Changed
rcX#-
andrsXYZ~#-
to properly capture the typed number.
Added mouse HotKey Back button for going up one folder level while in Explorer.
Added mouse HotKey Forward button for going to the previous folder while in Explorer.
Added the following functions:
containsEol()
- returntrue
if the specified string contains an end-of-line character (Windows/DOS, Unix or Mac), otherwisefalse
getHwndForPid()
- returns thehWnd
for the specified process IDgroup()
- convenience function to generate an "ahk_group" stringisActiveExplorer()
- returnstrue
if the active window is Windows Explorer, otherwisefalse
Code refactoring using the new functions.
Minor code cleanup for consistency.
Fixed issue with Shift + Win + NumPad7/8/9 keys being triggered as though they were Shift + Win + NumPad4/5/6 even though the actual keys were never defined as a HotKey. This seems to be a limitation of AutoHotkey itself. Because of this issue, it will be difficult to assign user-defined HotKeys to these particular combinations.
Fixed issue with using Win + G when the active window is a DOS window and a process was running. The process would be terminated because HotScript tries to determine any selected text by issuing a Ctrl + C.
Changed the order of repeat character from
rc#-X
torcX#-
which types more naturally.
Changed the order of repeat string from
rs#-XYZ
torsXYZ~#-
which types more naturally.
Added the following functions:
getSelfHwnd()
Added optimizations to
repeatStr()
that allow it to run faster and more efficiently when the repeat count of the string is greater than 10.
Added safety checking for auto-updates of both AutoHotkey and HotScript which should prevent future errors from occurring, which at times would leave HotScript not fully functional. If HotScript detects there is something wrong with the update of either, a window will be displayed indicating the issue and a request to post a message to the forum (so it is brought to our attention and can be fixed).
Modified some URLs from "http" to "https".
Minor code cleanup for consistency.
Fixed an issue with auto-updating AutoHotkey, which was caused by a change to their website.
Added mouse HotKey Ctrl + Win + Left button to center the mouse pointer on the current screen.
Added mouse HotKey Shift + Win + Left button to center the mouse pointer on the current screen.
Changed Ctrl + Shift + Space to be Ctrl + Alt + Space for deleting blank lines.
Changed Ctrl + Shift + Backspace to be Ctrl + Alt + Backspace for sending End, Backspace, and Down.
Changed Ctrl + Shift + End to be Alt + End for sending Up, End, and Delete.
Added HotString
rc#-X
to repeat a character any number of times. The HotString trigger breaks down as follows:rc --> repeat character # --> any positive number 1..9999999 - --> any symbol or white-space separator (see below for valid choices) X --> the letter to be repeated
It is necessary to have some type of separator between the number and the character because the character itself may be a number and there would be no way to distinguish between the number of times to repeat and the actual character to repeat.
symbols : `~!@#$%^&*()-_=+[]{};:'",.<>/? white-space: Space, Tab, or Enter
Note: when repeating values above 1 million times, it will take longer to produce the string, which depends on the speed of your computer -- be patient.
Added HotString
rs#-XYZ~
to repeat a string any number of times. The HotString trigger breaks down as follows:rs --> repeat string # --> any positive number 1..9999999 - --> any symbol or white-space separator (see above for valid choices) XYZ --> the string to be repeated (may contain any characters, except ~) ~ --> To signal the end of the string, the ~ character was chosen
It is necessary to have some type of separator between the number and the start of the string because the string itself may start with a number and there would be no way to distinguish between the number of times to repeat and the first character of the string.
It is not possible to paste any text into this HotString.
Note: when repeating values, that larger the string, the longer it will take to produce the final string, which depends on the speed of your computer -- be patient. Also, it is easy to run out of memory trying to repeat a large string many times.
For HotStrings in DOS, they were not getting properly reset when ESC was pressed which would result in the HotString not being executed when it should.
Added the following functions:
hsRepeatString()
- Associated with built-in HotStringrs#-XYZ~
runCapture()
- Runs a DOS command, captures the output and returns it
Modified isProcessSuspended() to hopefully execute slightly faster.
Modified runTarget() to more often be successful in activating the newly launched application. The PID for the launched application will now be returned by the function.
Added additional information to help screen to differentiate when to scroll the mouse wheel and when to tilt the mouse wheel. Open-ended arrows are used to indicate mouse wheel activity, whereas closed-ended arrows represent keys to be pressed.
Modified the URL for Google Image Quick Lookup from
http://images.google.com/images?q=@selection@
tohttps://www.google.com/search?q=@selection@&tbm=isch
.
Modified all Google/YouTube URLs for Quick Lookup to use
https
.
Corrected the arrows on the help screen for scrolling left/right Ctrl + WheelUp and Ctrl + WheelDown. The previous arrows were pointing in the wrong direction.
Adjusted some of the colors of the help screen.
Minor code cleanup for consistency.
Added tray menu option for launching the HotScript live chat in the default browser.
Added tray menu option for launching the HotScript forums in the default browser.
Fixed issue with
centerMouse()
not calculating correct center when using multiple monitors.
Added HotKey Ctrl + CapsLock to center the mouse pointer on the current screen.
Added HotKey Shift + CapsLock to center the mouse pointer in the current window.
Added the following functions:
centerMouse()
- centers the mouse either on the screen or within a windowhkMiscCenterMouseScreen()
- Associated with built-in HotKey Ctrl + CapsLockhkMiscCenterMouseWindow()
- Associated with built-in HotKey Shift + CapsLock
Modified the function signature of
MouseClickDrag()
andMouseMove()
to userelative
as a boolean flag instead ofR
.
Fixed very minor typo in
showWindowInfo()
.
Added HotKey Ctrl + Shift + Delete to delete text to the start of the line. This also works in DOS.
Added HotKey Ctrl + Shift + Backspace to delete the last character on a line and move the cursor down one line.
Added HotKey Ctrl + Shift + End to join lines of text by sending Up + End + Delete. This works if the cursor is on the first line, last line, or any place within text. Pressing the HotKey repeatedly will eventually join all lines.
Modified Ctrl + Delete when used in Microsoft Word to be one character less, which is necessary to avoid deleting a paragraph marker. It should still function as expected even if the current line does not have a paragraph marker.
Removed Ctrl + Delete from "DOS Keys" of help screen. It still works the same, but was redundant to the same entry in "Text Keys".
- Added the following functions:
hkTextDeleteToSol()
- Associated with HotKey Ctrl + Shift + DeletehkTextEndBackspaceDown()
- Associated with HotKey Ctrl + Shift + BackspacehkTextUpEndDelete()
- Associated with HotKey Ctrl + Shift + End
Removed
hkDosDeleteToEol()
and moved the functionality intohkTextDeleteToEol()
.
Added window group for Microsoft Word (MSWordGroup) and for Microsoft Excel (MSExcelGroup).
Moved some sections around on the help screen to allow for future entries on some of the more popular/active sections.
Added HotKey Ctrl + Alt + M to uppercase MySQL keywords and functions for any selected text.
Added the following functions:
upperCaseMySql()
- For the selected text, any MySQL keywords are converted to uppercaseupperCaseSqlWords()
- shared function forupperCaseMySql()
andupperCaseOracle()
Refactored the common parts of
upperCaseOracle()
intoupperCaseSqlWords()
.
Added configuration option
mySqlTransformRemainderToLower
which will set to lowercase any text that was selected that is not a MySQL keyword or function.
Corrected issue with
hotString()
where some regex-based HotStrings were not working properly.
Added HotKey Ctrl + Alt + . to delete white-space at the end of each line of text that is selected. If no text is selected, all text will automatically become selected, then white-space will be deleted.
Added HotKey Ctrl + Shift + Space to delete all blanks lines from text that is selected. If no text is selected, all text will automatically become selected, then blank lines will be deleted.
Added the necessary support functions for resizing windows to
1x4
,2x4
,4x1
and4x2
.
Corrected the dimension calculations associated with 2x4 and 4x2.
Fixed bug introduced in 1.20170205.1 where anything relying on isActiveDos() would not function properly. This was most noticeable with HotStrings not working in DOS.
Fixed bug introduced in 1.20170119.1 where many of the window resizing HotKeys would not move/resize the window, but would instead paste the name of the function related to the HotKey.
Fixed a very old bug where typing the trigger of a HotString that ends with a Tab character, HotScript would go into an infinite loop of holding down the Shift and Left keys. This has been changed to ignore the HotString (only when it ends in a Tab character and only when in a DOS window). It seems far more likely the intent from the user would be filename/directory completion.
Added the following functions:
- deepCopy() - creates a deep copy of an object or array
- equals() - used to check two variables for equality
- equalsIgnoreCase() - used to check two variables for equality, ignoring case for strings
- getHwnd() - gets the handle of a window
- getWindowInfo() - gets information for a window
- merge() - merges an object or array with the specified values
- mergeArray() - merges an array with the specified values
- mergeObject() - merges an object with the specified values
- isWindowVisible() - returns true if the specified window is visible
- toHex() - converts an integer value into its equivalent hex value
Added window resizing dimensions:
1x4
,2x4
,4x1
and4x2
. There is not a HotKey for these because there are no remaining good combinations to be used. There is however a feature in the works to allow for easily choosing screens dimensions which will free up most of the HotKeys currently used by window resizing/positioning. Stay tuned! You may create a HotKey for any of these new options.
Added much more information to showWindowInfo().
Renamed
getActiveMonitor()
togetMonitorForWindow()
.
Modified
contains()
to handle arrays and objects. This also affectscontainsIgnoreCase()
.
Fixed a minor formatting bug with
toString()
.
Refined the help screen to combine similar HotKeys to use less space. Improved consistency for HotKeys that have more than one combination. Better use of colors. The more complex HotKeys should be easier to understand. It is just a quick help screen and not meant to be full documentation.
Some internal refactoring for consistency and reliability.
New HotKeys for wrapping text in symbols. Previous only a few symbols were supported:
[] {} () <> ' "
. Now all symbols from the US keyboard are supported:`` ~ ! @ # $ % ^ & * () - _ = + [] {} \ | ; : ' " <> , . / ?
. The HotKeys are Ctrl + Win + SYMBOL for wrapping all of the selected text (or just the current line if no text is selected), or Ctrl + Alt + Win + SYMBOL for wrapping each individual line. As a result the previously defined HotKeys for wrapping text have been changed.
Added HotKey Ctrl + Alt + Insert as an additional HotKey for "Copy Append". The existing HotKey of Ctrl + Alt + C still works. The reason for the new one is for long-time users of DOS where we learned Ctrl + Insert (copy) and Shift + Insert (paste). Some habits cannot be changed! FYI - these legacy HotKeys are still supported by Windows (thankfully).
Changed HotKey for escaping text for AHK from Ctrl + Shift + ` to Ctrl + Alt + `.
Added HotString
@bullet
to generate a bullet character.
Added HotString
@club
to generate a club character.
Added HotString
@copy
to generate a Copyright character.
Added HotString
@diam
to generate a diamond character.
Added HotString
@ellip
to generate a ellipsis character.
Added HotString
@heart
to generate a heart character.
Added HotString
@mdash
to generate a MDash character.
Added HotString
@ndash
to generate a NDash character.
Added HotString
@reg
to generate a Registered character.
Added HotString
@spade
to generate a spade character.
Added HotString
@tm
to generate a Trademark character.
Added HotString
@uniXXXX
to generate the Unicode character represented by the hex value XXXX.
Consolidated functionality of several "one-off" functions into
hkTransformWrap()
. This function now handles all traditional symbols that have keys on a standard US keyboard.
Removed obsolete functions:
hkTransformWrapEachInBrackets()
hkTransformWrapEachInCurlys()
hkTransformWrapEachInParenthesis()
hkTransformWrapEachInDoubleQuotes()
hkTransformWrapEachInSingleQuotes()
hkTransformWrapEachInTags()
hkTransformWrapInBrackets()
hkTransformWrapInCurlys()
hkTransformWrapInParenthesis()
hkTransformWrapInDoubleQuotes()
hkTransformWrapInSingleQuotes()
hkTransformWrapInTags()
Fixed a bug with
output()
that would cause any thread that called it to stop working.
Fixed a bug with
runFunction()
andshowVariable()
that would (rarely) cause the buttons displayed on the dialog to be in the wrong location or the wrong size.
Refined the help screen to show better information (color, symbols, etc) using less space. As a result, the help screen is now a little smaller, allowing it to fit onto laptop displays (1366x768) without being cut off.
Modified the configuration for HotKeys that have more than one HotKey associated to it. The entries were written as
hkWindowLeft-1
andhkWindowLeft-2
, but are now written ashkWindowLeft-01
andhkWindowLeft-02
to allow them to be sorted properly in theHotScriptDefault.ini
file.
Minor code cleanup.
Added tray menu option for checking for a new version of HotScript. This is different than the automated daily check because it will always compare the current version against the latest version even if the automated check has already run for the day. The automated check runs once once per day.
Added HotKey Alt + Win + F12 to run an internal function. This is primarily for debugging your own functions but may have other uses. It is still experimental and does not (yet) support parameters.
Added the following functions:
output()
- Displays the specified string in a windowrunFunction()
- Executes a function by name (does not yet support parameters)
Changed
message()
to return the name of button that was clicked, which eliminates the need to useIfMsgBox
.
Fixed an issue with
centerControls()
being unable to detect windows whose title contains certain symbols. This would cause the controls to be incorrect displayed in the dialog.
Added support to
menuBuilder()
for menus to automatically include an icon if the corresponding function name is defined. A different icon can show for when the function is defined as well as for when it is not. Within the primary menu object, use therunIcon
andwarnIcon
boolean flags to enable displaying the icons.
Fixed a minor cosmetic issue in
menuBuilder()
where the primary menu color would increment by one for each time the menu was shown instead of always showing the first defined color.
Fixed the comment header for Perl and SQL to use the correct indentation.
Added the following functions:
- isArray() - returns
true
if the specified value is an array- isEmpty() - returns
true
if an empty string or empty object/array- menuBuilder() - takes an object parameter describing the menu to be built and creates it
- menuHandler() - companion to
menuBuilder()
, it handles all actions of the menu dynamically calling functions- toSafeName() - used by
menuBuilder()
to generate dynamic, yet safe, function names for each menu item
Modified
toString()
to use the correct brackets for the object type, when applicable:[]
for array,{}
for objects and<>
for all other objects. Note: empty arrays cannot be properly detected and will show as empty objects.
Add a constant
hs.const.MENU_COLORS
for menu colors. There are seven pre-defined colors:
- yellow (FFFEE3)
- blue (D7DEEF)
- red (FFE2E3)
- green (D9F4DC)
- purple (E4D6EF)
- cyan (D2EAEC)
- orange (FFE3D1)
Modified the creation of
HotScriptFunctions.ahk
,HotScriptKeys.ahk
,HotScriptStrings.ahk
, andHotScriptVariables.ahk
to use correct Windows line ending characters (CRLF) instead of Unix/Linux line-endings (LF).
Modified the behavior of
checkVersions()
, because as of version 1.1.24.02, AutoHotkey has changed the filename of their installation file. This was causing HotScript to fail when it detected a new version of AutoHotkey to be installed. Previously, new versions of AutoHotkey were named likeAutoHotkey112401_Install.exe
but is now available asAutoHotkey_1.1.24.02_setup.exe
. For existing users of HotScript, the best solution for now is to manually download and install the new version of AutoHotkey and then manually install the new version of HotScript. While this should only affect a small number of users, it is inconvenient. This should no longer happen regardless of the name of the AutoHotkey installation. Further verification checks are being done to validate that any new version of AutoHotkey that is downloaded is a valid file.
Changed action for DOS HotKey Alt + Up (or Alt + .) to run
cd ..
instead ofcd..
. Linux/Unix wants the space between thed
and.
whereas DOS did not care. This is helpful for DOS windows running SSH (like Putty) to access a Linux/Unix server.
Added some additional checking with Delete Word
Ctrl-D
to determine is Microsoft's Visual Studio Code is the active Window. If so, need to treat it differently because Ctrl + C, fromgetSelectedText()
, will copy the entire line if there is no selection. This is a temporary workaround until a better solution can be found.
Renamed
findOrRunByExe()
tofindAndRun()
.
Moved error logic from
hkActionWindowsSnip()
tofindAndRun()
.
Removed unnecessary functions:
StringLower()
StringUpper()
Made a minor change to the help screen for to indicate that no additional modifier key is required for "Row 1" on HotKeys that resize the window to
3x4
,4x3
and4x4
.
Restored original functionality of Alt + Down within Windows Explorer. Previously it was trying to execute the functionality for "Move line down", but this made no sense in Explorer.
Restored original functionality of Alt + Up within Windows Explorer. Previously it was trying to execute the functionality for "Move line up", but this made no sense in Explorer.
Restored original functionality of Ctrl + Shift + E within Windows Explorer. Previously it was trying to execute the functionality for "Encrypt text", but this made no sense in Explorer.
Restored original functionality of Ctrl + Shift + N within Windows Explorer. Previously it was trying to execute the functionality for "Auto-Number (1)", but this made no sense in Explorer.
Modified
message()
to accepttitle
,options
andtimeout
. These have default values, so no changes are required for existing usages.
Fixed issue with auto-update not working correctly.
Modified to run with admin privileges because of a few small writes to the registry. This eliminates the need to modify the shortcut to allow access.
The Windows link (shortcut) file to auto-run HotScript will now only be created if it does not exist instead of every time HotScript is executed or reloaded.
Modified the URL pointing to GitHub from
release
tomaster
. This should have no effect as both branches were kept in sync. Eventuallyrelease
will be phased out and a newbeta
branch may be available for anyone interested in using the latest and greatest development version (which is what I use everyday). This will be an opt-in setting eventually.
Modified the help screen from
Level 1-4
to readRow 1-4
to help clarify the meaning as the optional modifier keys for resizing3x4
,4x3
and4x4
.
Removed some old, commented out code.
Added missing reference to "$" in the documentation within HotScriptKeys.ahk
.
Fixed minor issue in the documentation within
HotScriptKeys.ahk
that incorrectly referred to HotStrings.
Added window resizing dimensions:
1x3
,2x3
,3x1
,3x2
,3x4
,4x3
, and4x4
.
Added window resizing options for resizing to max height or max width. With multiple monitors, these functions will toggle between resizing between the current monitor and all monitors. The HotKeys are Shift + Win + Left + Right for resizing to max width and Shift + Win + Up + Down for resizing to max height. It is necessary to press both arrow keys SIMULTANEOUSLY or this HotKey will not be triggered. This is different than the existing HotKeys resizing to
2x2
, where you may press Shift + Win + ARROW1 then ARROW2 separately (but still holding the others).
Added HotKey Ctrl + MouseWheelUp and Ctrl + MouseWheelDown to scroll horizontally left/right, respectively.
Added HotKey Ctrl + D to delete from the current cursor position to the next word. It is important to note that different applications treat Ctrl + Shift + Right somewhat differently. As much as possible, consistency was implemented to overcome this. To see some of the differences between applications, see the comments in
hkTextDeleteWord()
.
Fixed issue with Ctrl + Delete where it was not issuing the correct keystrokes to delete the text.
Added the following functions:
- extractLocationAndResize() - Responsible for moving and resizing windows to a grid position
- getSelf() - returns the name of the function; increase the number to identify further up the call chain
- getStackTrace() - generates a stack-trace message
- horizontalScroll() - scrolls a window left or right horizontally
- isActiveCalculator() - returns
true
if the active window is Windows Calculator- isWord() - returns
true
if the specified string contains only word characters (letters, digits, and underscores)
Modified
getVarType()
to better distinguish between a string and a function.
Modified
runTarget()
to wait for the application for 1 second instead of indefinitely.
Renamed
isCalculatorNotActive()
toisNotActiveCalculator()
.
Modified
toString()
to more accurately display the name of a function.
Removed
resizeTo()
. It was replaced withextractLocationAndResize()
.
Fixed a small bug in
toString()
where labels were not being processed correctly.
Modified wait time of
ClipWait()
from 0.5 seconds to 0.05 seconds. This increases the speed of several operations like swapping selection with the clipboard, appending to the clipboard, getting the selected text and pasting text. These same operations are used by other functions as well as some HotKeys.
Throughout HotScript, when searching for named applications, they are no longer case-sensitive.
The help screen is now created (internally) only once instead of every time it is displayed.
The help screen will now be displayed on the active monitor instead of only the primary monitor.
Minor code cleanup and changes for consistency.
Added HotKey Ctrl + Delete (Delete to end-of-line) to the help screen. This HotKey had been implemented for quite a while, but was erroneously omitted from the help screen.
After upgrading to a new version of HotScript, a dialog will be displayed asking if the list of changes should be displayed. This is only applicable if
enableVersionCheck
is set totrue
. This will take effect for versions later than this one.
Added brief (2 second) notification that HotScript is being upgraded to a new version. This is only applicable if
enableAutoUpdate
is set totrue
. This will take effect for versions later than this one.
Fixed issue broken in 1.20160618.1 where user configuration values would be incorrectly removed from
HotScriptUser.ini
.
Added HotKey Win + / to display information about the current window.
All HotKeys are now defined using
hotKey()
instead of the manner expected by AHK.
Added
768x1024
andcustom
options to the Quick Resolution menu.
Fixed issue with Alt + Shift + , and Alt + Shift + . not working.
Modified auto-update to download to a temporary filename instead of HotScript.ahk and to test the integrity of the file. This was necessary because occasionally GitHub may be unavailable and the downloaded file would actually be GitHub's HTML error page.
Added configuration value to save the last date that a new version was checked for. This allows HotScript to now only search for a new version once per day instead of every reload.
Increased MaxHotkeysPerInterval (currently every 2 seconds) from 200 to 500.
Refactored the code for creating the help screen to only generate the content once, which should allow the screen to not only be displayed faster, but also may fix the issue with the help screen randomly appearing as blank.
Miscellaneous code cleanup.
Removed obsolete configuration values for
inputBoxFieldFont
andinputBoxOptions
.
Fixed issue with
enableHsVariables
not being saved properly.
Fixed issue with some configuration values being saved to HotScriptUser.ini
when they should not.
Added the following functions:
centerControls()
-clipboardAppend()
- Copies or cuts the selected text to any text already on the Windows clipboarddebugVar()
- Shows a global variable's valuehotKey()
- Dynamically registers a HotKeyshowWindowInfo()
- Shows information about the specified window; used by HotKey Win + /
Refactored
ask()
to support multi-line input as well as regular or monospace font.
Refactored
registerHotkey()
intohotKey()
, with better support for conditions and parameters.
Modified
centerWindow()
to be able to specify the monitor number for which to center the window.
Modified
checkVersions()
only execute once per day.
Added an
options
parameter toFileRead()
.
Added a parameter to
resizeWindow()
to indicate if the window should be centered after resizing it.
Refactored
toString()
to eliminate the depth restriction for objects and to indicate if a value is a function or label.
Removed the wrapper function
StringReplace()
, because AHK has a built-in function calledStrReplace()
.
Removed old migration code for version 1.20131211.2.
Removed
isWindow()
.
Removed
resizeToResolution()
. It was redundant toresizeWindow()
.
Fixed issue with
getIndent1()
sometimes returning an empty string. It now will always return some value.
Fixed issue with endless loop restarting/updating. The version file was updated but the internal version was not, so HotScript thought there was always a newer version to be downloaded.
Added a constant
hs.const.INDENT
for a default indent of 4 spaces.
Modified
getIndent()
to check if the active window is a DOS window. If so, it will use the new default constant value of 4 spaces, otherwise it will try to determine the indent level from the active window.
Added HotKey Ctrl + Alt + Shift + A to sort the selected text as case-sensitive in ascending order.
Added HotKey Ctrl + Alt + Shift + D to sort the selected text as case-sensitive in descending order.
Changed HotKey Ctrl + Shift + A to (sort the selected text in ascending order) to be as case-insensitive.
Changed HotKey Ctrl + Shift + D to (sort the selected text in descending order) to be as case-insensitive.
Changed the auto-correct HotString of
[a-z]L
to now be restricted to a word boundary, so that typing values such asStrLen
will no longer cause the HotString to be triggered.
Added missing HTML tag
thead
to HotString help screen.
Minor code cleanup.
Added the following functions:
compareStrAscNoCase()
- compares two strings in ascending order as case-insensitive
Numerous minor refinements to several of the
hsXxxYyy()
functions to produce better output, especially within editors that have varying degrees of sophistication (or a complete lack of, such as Notepad).
Modified
getIndent()
to handle different editors, producing a much more reliable determination of the current indentation level.
Fixed issue with
hsCodeFunction()
, used by thefunc(
HotString, not replacingfunc
withfunction
.
Fixed issue with
hsCommentHeaderPerl()
andhsCommentHeaderSql()
leaving the cursor on the wrong line.
Fixed
getIndent()
where if the start of a line contained more than only white-space, the wrong indent value was being used.
The HotKey Win + Pause was incorrectly wrapped by the
enableHkMisc
variable. If this variable was disabled, the Win + Pause HotKey (which pauses HotScript) would not be enabled. This is the only HotKey that is hard-coded and cannot be user-modified. While the Win + Pause HotKey could be overridden by some other function, it is not (currently) possible to reassign HotScript's pause function to another key combination due to the restrictions of AHK'sSuspend
command.
Changed the auto-correct HotString of
cL
to now include all drive letters (a-z).
Added
replaceMode
to thehs.const
object.
Made the
$
variable to be truly global. This variable is populated by hotString() when using regular expression HotStrings. Do NOT use this variable name for your own values.
Added the following functions:
getIndent()
- Returns the amount of white-space indentation for the current linegetIndent1()
- Returns one indentation level of white-space; typically used with the value fromgetIndent()
hsCodeBlock()
- Used to completefor(
,if(
, andwhile(
HotStringshsCodeElseIf()
- Used to completeelif
HotStringhsCodeFunction()
- Used to completefunc(
HotStringhsCodeIfElse()
- Used to completeifel
HotStringhsCodeStringFormat()
- Used to completesf.
HotStringhsCodeSwitch()
- Used to completeswitch(
HotStringhsCodeSysOut()
- Used to completesysout
HotStringhsCommentHeaderHtml()
- Used to completechh
HotStringhsCommentHeaderJava()
- Used to completechj
HotStringhsCommentHeaderPerl()
- Used to completechp
HotStringhsCommentHeaderSql()
- Used to completechs
HotStringhsHtmlA()
- Used to complete<a
HotStringhsHtmlComment()
- Used to complete<!-
HotStringhsHtmlHeader()
- Used to complete<h(1-6)
HotStringhsHtmlHtml()
- Used to complete<html
HotStringhsHtmlInput()
- Used to complete<input
HotStringhsHtmlLink()
- Used to complete<link
HotStringhsHtmlList()
- Used to complete<ol
and<ul
HotStringshsHtmlOptGroup()
- Used to complete<optg
HotStringhsHtmlSelect()
- Used to complete<select
HotStringhsHtmlSource()
- Used to complete<source
HotStringhsHtmlStyle()
- Used to complete<style
HotStringhsHtmlTable()
- Used to complete<table
HotStringhsHtmlTagAbbr()
- Used to complete<but
,<cap
,<field
,<foot
,<opti
, and<sum
HotStringshsHtmlTagBlock()
- Used to complete<block
,<body
,<div
,<form
,<header
,<hgroup
,<script
,<section
,<tbody
,<tfoot
, and<thead
HotStringshsHtmlTagFor()
- Used to complete<label
HotStringhsHtmlTagNoEndChar()
- Used to complete<b
,<head
,<i
,<li
,<p
,<q
,<th
, and<u
HotStringshsHtmlTagSimple()
- Used to complete<big
,<code
,<del
,<em
,<legend
,<pre
,<small
,<span
,<strong
,<sub
,<sup
,td
, and<title
HotStringshsHtmlTagSrc()
- Used to complete<iframe
and<img
HotStringshsHtmlTextarea()
- Used to complete<texta
HotStringhsHtmlTr()
- Used to complete<tr
HotStringhsJiraCode()
- Used to complete{code
,{java
,{js
,{sql
and{xml
HotStringshsJiraColor()
- Used to complete{color
HotStringhsJiraNoFormat()
- Used to complete{nof
HotStringhsJiraPanel()
- Used to complete{bpan
{gpan
,{pan
,{rpan
and{ypan
HotStringshsJiraQuote()
- Used to complete{quo
HotStringhsJiraSpecialPanel()
- Used to complete{info
,{note
,{tip
and{warn
HotStringshsJiraTable()
- Used to complete{table
HotString
Swapped position of
clear
andcondition
in the function definition ofhotString()
.
Renamed
hsBackInX()
tohsAliasBackInX()
.
Renamed
sendJiraCode()
tohsJiraCode()
.
Renamed
sendJiraPanel()
tohsJiraPanel()
.
Renamed
sendJiraSpecialPanel()
tohsJiraSpecialPanel()
.
Renamed
templateJiraTable()
tohsJiraTable()
.
Minor change to prepended text in
debug()
.
Removed obsolete function
hkToStr()
.
Added a link on the help screen to open the HotScript home page in the default browser.
Added an option on the tray icon to display the help screen.
Refactored all internal HotStrings to use
hotString()
instead of the mechanism used by AHK. This will help with some future changes as well as reducing the amount of code. It should now be possible to define any HotString usinghotString()
, which can have much more flexibility than offered by AHK. I strongly recommend converting your existing user-defined HotStrings to use this new method. When usinghotString()
,addHotString()
no longer needs to be called to update the metrics.
Rearranged the help screen for HotStrings.
Trying to fix a bug when showing the help screen. Randomly the screen will show without the text displayed. If you click and drag with the mouse, the text will show. Still working on this issue, but it seems better.
Added HotKey Ctrl + Alt + C to copy/append text to the clipboard. This does NOT work for files.
Added HotKey Ctrl + Alt + V to swap the currently selected text into the clipboard, replacing the selected text with the previous contents of the clipboard.
Added HotKey Ctrl + Alt + X to cut/append text to the clipboard. This does NOT work for files.
Added HotKey Ctrl + Win + ARROW to move the current window to the edge of the screen, without resizing it.
Added HotKey Win + M to run Character Map.
Added HotKey Alt + Win + H to run Windows Explorer in the HotScript folder.
Added HotKey Alt + Win + S to run Windows Explorer in the Startup folder.
Added HotKey Win + ` to run DebugView.
Modified the HotKeys for dragging the mouse from Ctrl + Win + ARROW to Ctrl + Alt + Win + ARROW to avoid collision with the new "Move to Edge" HotKeys.
Moved the HotKey definitions for dragging the mouse into the appropriate section
Miscellaneous
.
Changed HotKey for "Toggle Minimized" from Win + M to Ctrl + Win + M.
Changed HotKey Win + V (Preview Clipboard) to indicate if the data is complex and therefore cannot be previewed.
Added back previous error checking when running Snipping Tool via Win + PrintScreen for Windows 2008 but also added checking for Windows 2012.
Deleted the
hkCustom
HotKey section (and configuration setting), moving the only remaining entry into the hkText section.
Added HotString
@dob
to use the variableMY_DOB
.
Added HotString
@pw
to use the variableMY_PASSWORD
. The value is encrypted using the same function as Ctrl + Shift + E and will be unencrypted when this HotString is used.
Added HotString
@w
to use the variableMY_WORK_EMAIL
.
Added HotStrings for the following fractions:
1/6
,1/5
,2/8
,2/6
,2/5
,2/4
,3/6
,4/8
,3/5
,4/6
,6/8
,4/5
, and5/6
. Some fractions may be reduced are will therefore use the reduced fraction, for example:4/8
will return the fraction for1/2
.
Changed trigger for fractions to start with some type of separator (
3 1/2
instead of31/2
).
Changed several HotStrings (
@addr
,@ip
,@me
,@sig
) to be case-sensitive.
Changed how fraction HotStrings are defined; they now use
hotString()
.
Changed how date and time HotStrings are defined; they now use
hotString()
.
Added global variable
MY_DOB
.
Added global variable
MY_PASSWORD
.
Added global variable
MY_WORK_EMAIL
.
Added configuration setting
enableHsVariables
for enabling/disabling HotStrings for HotScriptMY_xxxxxx
variables.
Any
MY_xxxxxx
variables (inHotScriptVariables.ahk
) will now be automatically added with a default value if they are missing. This means that there is no longer a need to manually edit this file to add new variables that will be supported in future versions of HotScript, but this file will still need to be edited by the user to provide the appropriate real values to be used.
Added the following functions:
getActiveProcessID()
- Returns the PID for the active processgetActiveProcessName()
- Returns the name for the active processgetDateString()
- Returns the current date in the format ofMM/DD/YYYY
getDayString()
- Returns the name for the current day of the weekgetDddString()
- Returns the three-letter abbreviation for the current day of the weekgetDtmsString()
- ReturnsgetDtsString()
+_
+getTmsString()
getDtsString()
- Returns the current date stamp in the format ofYYYYMMDD
getMmmString()
- Returns the three-letter abbreviation for the current monthgetMonthString()
- Returns the name for the current monthgetNowString()
- ReturnsgetDateString()
+at
+getTimeString()
getTimeString()
- Returns the current time in the format ofHH:MM:SS
(24-hour)getTmsString()
- Returns the current time stamp in the format ofHHMMSS
(24-hour)isActiveDos()
- Returnstrue
if the active window is part ofDOSGroup
isCalculatorNotActive()
- Returntrue
if the active window is not Windows CalculatormoveToEdge()
- Moves a window to either the top, bottom, left, or right edge of the screenpad()
- Adds padding to either the left or right side of a string valueparseTemplate()
- Replaces tokens with actual values within a template
Added support for user-defined initialization function called
userInit()
. Because of how AutoHotkey works, do not define HotKeys or HotStrings within theuserInit()
function. These should be placed inHotScriptKeys.ahk
orHotScriptStrings.ahk
. Failure to do so will almost certainly cause significant parts of HotScript to stop functioning.
Modified
toBool()
to returntrue
if the value is a number and greater than zero.
Modified
hotString()
to use any return value from a named function as the replacement text.
Renamed
showDebugVar()
toshowVariable()
.
Improved output of
showVariable()
.
Improved output of
toString()
.
Enhanced output of
templateHtml()
.
Modified
resizeTo()
for Windows 10. This affects all window movement HotKeys. Windows 10 puts transparent borders around non-maximized windows along the left, right and bottom of a window. When these windows line up next to each other, "gaps" appear which show whatever is underneath the windows. I found this quite annoying, so the math was changed for Windows 10 to accommodate these gaps. The coordinates are adjusted as follows: X +6, Y +1, Width +16, Height +9.
Added "Historical changes" to the HotScript tray menu.
Huge refactor of the help screen! To switch between tabs with keyboard use Ctrl + PgUp or Ctrl + PgDn. Press ESC to close.
Changed configuration setting for
enableAutoUpdate
fromfalse
totrue
.
Added
#32770
(Open/Save dialog) as a member of theExplorerGroup
.
Fixed issue with the
bi##
HotString not displaying the##
.
Added HotKey Ctrl + Alt + D to create a folder (directory) in Explorer or on the desktop.
Added HotKey Ctrl + Alt + F to create a file in Explorer or on the desktop.
Added HotKey Alt + Win + D to open a DOS window to the current path in Explorer, if it is the active Window.
Added the following functions:
- createNewInExplorer() - Creates either a new file or directory within Windows Explorer
- createNewOnDesktop() - Creates either a new file or directory on the Windows Desktop
- getExplorerPath() - Returns the current path being viewed within Windows Explorer
- getUniqueNewName() - Given a base name, will return a guaranteed unique file or directory name (prevents duplicates)
- selectInExplorer() - Selects item(s) within Windows Explorer
- selectOnDesktop() - Selects item(s) on the Windows Desktop
Improved the ability to launch Explorer via Win-X. Now it will activate an existing window, if it exists but is not focused. The default starting location will be the root of the
SystemDrive
(as defined by Windows) instead ofC:\
.
Modified
runDos()
to accept apath
, which will be the active directory when DOS is executed.
Increased sleep time from 100ms to 250ms when launching an application to allow more time for the window to exist. This may help with certain issues where the application is launched, but is not activated (focused).
Added HotString
@me
to use the variableMY_NAME
Added HotString
@sig
to use the variableMY_SIGNATURE
Added HotString
#/#%
which divides two numbers and returns the result as a percent
Added HotString
#%#
which returns the percentage of the first number in relation to the second number
Added HotString
lmk
.
Added HotString
vg
.
Internal changes to
@ip
to allow it to be easily overridden with a custom function
Added a
.
to the end of some of the aliases on the help screen to signify that an ending character is needed
Added global variable
MY_NAME
.
Added global variable
MY_SIGNATURE
.
Minor change within
hotString()
to calladdHotString()
only if any conditional function returns true
Minor renaming of variables and optimization within
hotString()
Removed
GetKeyState()
because it now conflicts with AutoHotkey's internal function with the same name
Removed
getHotKeySections()
because it was an obsolete function from a very old version
Added missing HotString
@#
to the help screen
Minor internal changes to how the headers of the
HotScript-*.ahk
files are written
Added additional information to the headers of
HotScript-Strings.ahk
to include dynamic HotStrings
Added HotKey
Win
+0
to launch the HotScript homepage.
Added smarter control to
Win
+G
to allow running of files/directories (if they exist) or UNC paths.
Swapped
Win
+6
andWin
+8
to allowWin
+8
andWin
+9
to be next grouped together.
Added HotString
@#
to use the variableMY_PHONE
.
Fixed a known limitation of being unable to use a tab as an ending character to a dynamic HotString. This was only an issue for HotStrings that would be replaced (rather than just appending text). Because some editors can be configured to insert (a variable number of) spaces instead of a tab, it was not easily knowable how much backspacing was required in order to erase the trigger string. While this is now slightly slower than normal (only when using a tab), it is working correctly. The reason for it being slower is that the text entered must be selected one character at a time until the start of the trigger can be found.
Added global variable
MY_PHONE
.
Added the following functions:
isDirectory()
- Returnstrue
if the specified string is a directoryisFile()
- Returnstrue
if the specified string is a fileisUNC()
- Returnstrue
if the specified string is a UNC path
Fixed issue with
ask()
returning any value entered even if the user closed dialog, click cancel or pressedEscape
.
Added menu item to launch the HotScript homepage from the system tray icon.
Added configuration flag to disabling auto-updates (auto-update is on by default - may be disabled via
enableAutoUpdate
inHotScriptUser.ini
).
Added ability to create an auto-startup link (may be disabled via
enableAutoStart
inHotScriptUser.ini
).
Added status (
enabled
orsuspended
) to system tray icon tool-tip.
After upgrading the version of AutoHotkey, the downloaded installer will be deleted.
Removed warning message about being unable to obtain version information if an internet connection is not available at startup.
Removed unwanted menu items from the system tray icon.
Made changes that may have finally corrected intermittent issues with pasting text to a DOS window.
When pasting text to DOS that was created using a continuation section, the EOL needs to be converted to CRLF.
Increased delay to select the last known window when restoring previously minimized windows (via
Win
+M
).
Fixed issue with pasting large text in a DOS window. There is no longer a size limit.
Fixed issue with auto-update getting wrongly disabled.
Added HotKey
Win
+M
for toggling windows minimized/restored.
Added HotKeys
Ctrl
+Home
andCtrl-End
for scrolling to top or bottom of a DOS window.
Improved scrolling within a DOS window for
PgUp
andPgDn
functionality. It now scrolls exactly one page regardless of the actual size of the window.
Added HotString
@@
to use the variableMY_EMAIL
.
Added HotString
@addr
to use the variableMY_ADDRESS
.
Started preparation of changing HotStrings from internally hard-coded to be user configurable. This means HotStrings may now be defined via a regular expression (regex), which adds tremendous power and flexibility. While it can also mean slightly more work to setup very complex HotStrings, many more things can be achieved. This functionality is only in the beginning stages - much more work needs to be done here.
Added global variable
MY_EMAIL
. Added global variableMY_ADDRESS
.
Added the following functions:
getVarType()
- returns the type for the specified variable (Function
,Label
,Number
,Object
, orString
)urlToVar()
- returns the result of an HTTP request
Added version checking and simple updating (at startup/reload) for both AutoHotkey and HotScript. A prompt is shown to the user with the current/new versions and asks for permission to download/install the new version(s).
Added new configuration setting
enableVersionCheck
to disable version checking.
Added window marker ፨ for
Pinned
, which is a feature that may be implemented in a future release.
Changed several window marker symbols:
- (Always-on-top) from † to ᛂ
- (Click-through) from ‡ to ᚾ
- (Transparent) from ± to ≡
A warning message (about instability) is now displayed when pasting large amounts of text (> 4K) into a DOS window
Fixed a small error on the quick help screen -
Resize to NE
andResize to NW
were reversed.
Changes in versions from 1.20131211.2 through 1.20150821.2 were not maintained separately and are listed below as belonging to a single version.
Added HotKey Ctrl + Win + R for quickly resizing the active window to popular or custom sizes.
Added Hotkey Ctrl + Shift + Up to duplicate the current line.
Added HotKey Win + T to toggle the window transparency to 50%.
Added HotKey Ctrl + Win + A to toggle click-through for the active window.
Added DOS HotKey Alt + Up to go parent directory, which is the same as the existing HotKey Alt + ..
Added DOS HotKey Ctrl + Delete to delete to end-of-line.
Added DOS HotKey Ctrl + PgDn to scroll window down. Alt + PgDn and Shift + PgDn also work.
Added DOS HotKey Ctrl + PgUp to scroll window up. Alt + PgUp and Shift + PgUp also work.
Added DOS HotKey Ctrl + V to paste text (for Windows versions previous to 10).
Added HotKey Ctrl + Shift + ` to escape text for use within continuation sections.
Added
DECODE
andSTDDEV
keywords to the HotKey Ctrl + Shift + O for transforming Oracle keywords to upper case.
Added 467 more keywords to the HotKey Ctrl + Shift + O for transforming Oracle keywords to upper case.
Wrapping transformations now toggle, meaning they either add or remove the symbols to be wrapped.
Wrapping transformations now have an option for wrapping each line of selected text
Changed HotKey for Ctrl + Shift + [ that used to wrap in
{}
to now wrapping in[]
.
Removed the following HotKeys:
- Alt + Shift + ,
- Ctrl + Shift + B
- Ctrl + Shift + P
- Ctrl + Shift + Q
Removed certain HotKeys that are fairly specialized and of little interest to the typical users of HotScript
- Win + F (Run FileLocator Pro)
- Win + P (Run Perforce)
- Win + R (Run RegexBuddy)
Added common fractions
1/8
,1/4
,1/3
,3/8
,1/2
,5/8
,2/3
,3/4
,7/8
. Typing one of these HotStrings will produce the actual fraction symbol. The window in which this is types must support UTF-8 characters or else some of the fraction symbols will be displayed as a box.
Added HotString
@ip
that will produce the first IP address used by the computer.
Changed HTML and XML HotStrings containing attributes to use
'
instead of"
.
Fixed HotStrings not working in a DOS window (paste vs
SendInput
).
Added the following functions:
arrayToList()
- converts an array of items into a delimited listdebug()
- creates logging statements during development (requires DebugView from Microsoft)escapeText()
- can work both as a function returning a value or for selected textgetVar()
- returns the value of the specified global variable (supports values nested within objects)
Added a 2nd (optional) parameter to
pasteText()
for how long to delay.
Added a 3rd (optional) parameter to
sendText()
for how long to delay.
Added a 4th (optional) parameter to
pasteTemplate()
for how long to delay.
Changed
pasteTemplate()
to adjust the EOL character to WindowsCRLF
.
Added support for user-defined functions via the new file
HotScriptFunctions.ahk
.
Added support for user-defined variables via the new file
HotScriptVariables.ahk
.
Added several new selections within Quick Lookup Win + Q:
- Thesaurus
- Urban Dictionary
- Google Translate
- Google Maps
Added
ArrayList
class to be able to add key/value pairs to an array, but have the items stay in the order in which they are inserted. AutoHotkey's array will always sort entries by the key.
Added the version of AutoHotkey to HotScript's tray icon title.
At startup, the following registry settings will be changed:
- the default editor for AutoHotkey script files is changed to the configured editor
- the taskbar grouping of AutoHotkey scripts is turned off, to allow each script to display its own icon
Added the History section to the wiki.
Changed the quick help screen to hide information for disabled sections.
Improved the ability to properly detect the presence (or lack of) DOS windows.
Changed automatic updating of monitor information (number, resolution, placement) from 2 minutes to 30 seconds.
Changes were not recorded for versions 1.20130514.1 through 1.20131211.1.