{"id":1726,"date":"2023-10-13T10:01:53","date_gmt":"2023-10-13T10:01:53","guid":{"rendered":"https:\/\/www.ata-divisions.org\/AVD\/?p=1726"},"modified":"2023-10-13T10:01:53","modified_gmt":"2023-10-13T10:01:53","slug":"speed-up-your-subtitling-in-any-platform-using-autohotkey","status":"publish","type":"post","link":"https:\/\/www.ata-divisions.org\/AVD\/speed-up-your-subtitling-in-any-platform-using-autohotkey\/","title":{"rendered":"Speed up Your Subtitling in Any Platform Using AutoHotkey"},"content":{"rendered":"<p>by Adri\u00e1n Bergonzi<\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">A Little History: How I Discovered AutoHotkey<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">It was a long time ago. I had started working for a new subtitling agency and received my first assignment. Every new online system takes some time to get used to. Except this one, where the shortcuts were an absolute nightmare: Enter moved to the next subtitle, and Ctrl+Enter inserted a line break. One might think I\u2019m exaggerating, right? After all, it\u2019s just a shortcut. Well, no, we don\u2019t have a switch at the back of our head, and let\u2019s not forget that most of us work for several clients and some of them have their own subtitling platforms.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">So, as this particular system did not allow me to customize the shortcuts, I did a little research on how to \u201cchange keys in Windows.\u201d In no time, I had AutoHotkey installed and had written my first two macros. What I needed was simple: Enter must execute Ctrl+Enter (to insert a line break). I also needed another key to move to the next subtitle, which could be Tab or Page Down.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">So, what is AutoHotkey? In the words of its developers, it\u2019s \u201ca free, open-source scripting language for Windows\u201d which we can use to \u201cdefine hotkeys for the mouse and keyboard, remap keys or buttons\u201d and generate \u201cautocorrect-like replacements.\u201d<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Let\u2019s go back to our previous example and break down these two simple macros:<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"wp-image-1728 size-medium alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk1-300x77.jpeg\" alt=\"\" width=\"300\" height=\"77\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk1-300x77.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk1.jpeg 555w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"wp-image-1729 size-medium alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk2-300x77.jpeg\" alt=\"\" width=\"300\" height=\"77\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk2-300x77.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk2.jpeg 531w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">\u201cEnter::\u201d creates a macro on the Enter Key.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">\u201csendinput\u201d will send keys to the active window, where the cursor is. \u201cSendinput {Enter}\u201d will press the Enter key. \u201cSendinput ^{Enter}\u201d will send Ctrl+Enter. After each macro, don\u2019t forget to write \u201cReturn\u201d, which marks the end of each macro.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Beware that \u201csendinput enter\u201d will actually write \u201center\u201d, not hit the Enter key. Also, to add a shortcut to the Enter key, we use \u201cEnter::\u201d, not \u201c{Enter}::\u201d. These are two very common mistakes that can frustrate beginners.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">The \u201c^\u201d is a modifier used for the Control key. Other modifiers are \u201c+\u201d (Shift), \u201c!\u201d (Alt), and \u201c#\u201d (Windows key). Modifiers can be combined: \u201c^+a\u201d would press Ctrl+Shift+A. Keys can also be combined to create a macro; so, \u201c^+!PgDn::\u201d would create a macro on Ctrl+Shift+Alt+PageDown.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">The lines that start with \u201c;\u201d (semicolon) are comments. You can write anything you want in a comment to help you remember what a macro does.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Rest assured we are not hacking or tampering with any online system. Macros reside and get executed on our computer.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">The Tutorial<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">To learn how to install, create and execute scripts, I suggest you read the tutorial at <a href=\"https:\/\/www.autohotkey.com\/docs\/Tutorial.htm\">https:\/\/www.autohotkey.com\/docs\/Tutorial.htm<\/a>, specifically part 1, \u201cThe Basics.\u201d<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">To get started, download and install AHK 1.1 (version 2 is still in beta). To create a new file, right-click on any folder and choose New &gt; AutoHotkey Script. This will create a file that can be opened with any text editor, such as Notepad++. To execute the file, just double-click on it. Remember that one .ahk file can contain many macros.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Before attempting to write your own scripts, I strongly suggest you read the whole tutorial, as it will give you an idea of what AutoHotkey can do.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Using the Same Shortcuts Everywhere<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Shall we adapt to the subtitling system or vice versa? If the system adapts to us, we\u2019ll be more productive. In my case, I have designed a system of shortcuts that works for me in my favorite program (EZTitles), but nowadays most companies have their online subtitling systems. Some online platforms such as Ooona allow users to customize shortcuts, but when you can\u2019t, we can use macros.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">With AutoHotkey (AHK from now on), I can use the same keys for every company I work for. My play key is always \u201c5\u201d (numpad 5). It\u2019s \u201c5\u201d because it\u2019s in the center of the numeric keypad and because the key has a little ridge. \u201c4\u201d and \u201c6\u201d are one frame backward and forward. \u201c1\u201d and \u201c3\u201d jump back and forward (how many seconds depends on the system). \u201c7\u201d and \u201c9\u201d are the short jump back and forward. \u201c2\u201d and \u201c8\u201d speed down or up. \u201c0\u201d and \u201cperiod\u201d change the in-cue and out-cue of a subtitle. If you use a laptop without a numpad, you can always get a USB external numeric keypad.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">So, let\u2019s say a particular system has a shortcut to move one second forward with F2, but we need this to be on numpad 9, because it\u2019s the key we are used to:<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1731 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk3-300x90.jpeg\" alt=\"\" width=\"300\" height=\"90\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk3-300x90.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk3.jpeg 488w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Now we need a shortcut to move three seconds forward with numpad 3, but the system doesn\u2019t have a long jump forward shortcut to reassign. We can just create a macro and hit the short jump forward three times.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1732 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk4-300x87.jpeg\" alt=\"\" width=\"300\" height=\"87\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk4-300x87.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk4.jpeg 469w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">If there\u2019s a number I don\u2019t use, I turn it off. This is to avoid hitting it by accident and inserting digits into the text inadvertently. So, if a certain platform does not have a \u201cPlay 2X\u201d function, I turn off the numpad 8 key. This creates an empty macro that does absolutely nothing.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1733 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk5-300x64.jpeg\" alt=\"\" width=\"300\" height=\"64\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk5-300x64.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk5.jpeg 495w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Macros for Specific Applications<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">It wouldn\u2019t be wise to lose the ability to enter numbers with the numeric keypad when we\u2019re using Excel or any other application. So, to restrict our macros to work inside Google Chrome, we can use the following macro. Microsoft Edge users should use \u201cmsedge.exe\u201d instead of \u201cchrome.exe\u201d.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1734 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk6-300x111.jpeg\" alt=\"\" width=\"300\" height=\"111\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk6-300x111.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk6.jpeg 495w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Some Practical Examples<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Up until now, we have only reassigned keys. Let\u2019s see other examples that can come in handy.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Suppose that you\u2019re QCing a subtitle file and the translator used lowercase for forced narratives. But the style guide for this client requires all FNs to be in UPPERCASE. This happened to a friend.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">What could we do? Retype all the FNs? Of course not. Creating a macro that converts a subtitle to uppercase is as easy as ABC.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\" wp-image-1730 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk7-300x218.jpeg\" alt=\"\" width=\"318\" height=\"231\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk7-300x218.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk7.jpeg 505w\" sizes=\"(max-width: 318px) 100vw, 318px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">In this example, the macro is assigned to F6. First, we create a backup of the contents of the clipboard. We hit Ctrl+A (which selects all the text in the subtitle), Ctrl+C (which copies the text to the clipboard), and then convert the clipboard content to uppercase with the StringUpper command. Then we insert the new clipboard with SendInput and restore the previous clipboard.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Converting to \u201cSentence case\u201d is a bit more complex as AHK has no function to do this (it has StringLower, but we want sentences to start with uppercase). What we do is convert to lowercase and then capitalize the first letter of every sentence using a regular expression. Explaining regular expressions goes beyond the scope of this article, so here\u2019s the macro:<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\" wp-image-1740 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk8-300x155.jpeg\" alt=\"\" width=\"397\" height=\"205\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk8-300x155.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk8-348x180.jpeg 348w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk8.jpeg 674w\" sizes=\"(max-width: 397px) 100vw, 397px\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Changing three periods to an ellipsis as you type, as is required by Netflix guidelines, is the easiest macro. It just requires one line:<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-full wp-image-1735 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk9.jpeg\" alt=\"\" width=\"293\" height=\"44\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Similarly, if Fran\u00e7ois appears all the time in your show and you don\u2019t have a \u00c7 key, just type \u201cfrancois\u201d and let AHK replace it automatically with this macro:<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1736 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk10-300x38.jpeg\" alt=\"\" width=\"300\" height=\"38\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk10-300x38.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk10.jpeg 311w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Macros for SDH<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">For SDH, I found macros a must. I refuse to keep typing [Luis Fernando] and [Soraya] all the time, especially if a show has 150 episodes. In my case, I use a second keyboard just for macros.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">It\u2019s a cheap generic programmable keyboard (about 50 USD), designed to be used with a cash register. You don\u2019t need an expensive Elgato Stream Deck, which is beautiful and looks cool, but is somewhat costly. There are several POS programmable keyboards, featuring from 50 to 84 keys, and probably more.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">But you don\u2019t need a second keyboard if you\u2019re just starting out with macros. I\u2019ll show you how you can program a menu to enter characters\u2019 names just with two keys. One key brings up the menu, and another key types the character\u2019s name. You could also create macros to insert common SDH tags, such as [grunts] or [gasps].<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">For this example, we\u2019ll create a menu with three items. The first menu option will type \u201cMar\u00eda\u201d when you press number 1 (see macro below). \u201cMenuCharacters\u201d is the name of the menu we are creating. \u201c&amp;1\u201d assigns 1 to that menu item, so that \u201cMar\u00eda\u201d will get inserted when you hit \u201c1\u201d. \u201cInsertCharacterName\u201d is the name of the function that gets executed.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\" wp-image-1737 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk11-300x67.jpeg\" alt=\"\" width=\"345\" height=\"77\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk11-300x67.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk11.jpeg 527w\" sizes=\"(max-width: 345px) 100vw, 345px\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Now, we assign a shortcut to bring up the menu. In this case, F8. \u201c1200\u201d and \u201c600\u201d are the menu coordinates (change them based on your needs). We can tell AHK to calculate the center of the screen, but I\u2019m keeping it as simple as possible here. \u201cMenuCharacters\u201d must be the same name as before.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\" wp-image-1738 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk12-300x66.jpeg\" alt=\"\" width=\"336\" height=\"74\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk12-300x66.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk12.jpeg 310w\" sizes=\"(max-width: 336px) 100vw, 336px\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">The last step is to create the function that will get called when a menu item is activated. In our example, it must be \u201cInsertCharacterName\u201d, as before. This function will type the character name between square brackets using \u201cSendinput\u201d.<\/span><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">The previously-defined string to be inserted when number 1 is pressed was \u201c&amp;1 Mar\u00eda\u201d, so we use the function SubStr to omit the first three characters so that the text starts on the M.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\" wp-image-1744 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk13-300x93.jpeg\" alt=\"\" width=\"329\" height=\"102\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk13-300x93.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk13.jpeg 670w\" sizes=\"(max-width: 329px) 100vw, 329px\" \/><\/p>\n<p><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">And this is the menu we\u2019ve created. Just press F8, then 1, 2, or 3, and you\u2019ll get [Mar\u00eda], [Luis Fernando], or [Soraya] in your subtitles. This will save you time and help you avoid typos such as [Lius Ferdinando}.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Controlling Video from Microsoft Word<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">A colleague once had this issue: She was proofreading a dubbing script in Microsoft Word to, and the video was on VLC. How could she control the video without leaving Word? The mouse was out of the question. You never touch the mouse. The mouse is lava. Hitting Alt+Tab a million times would be crazy, too. So, who you gonna call? The macros.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">We could program a macro that would hit Alt+Tab, go to the player, press Spacebar in VLC (play), and hit Alt+Tab again to return to Word. This would work, but there\u2019s a better way. Just send the command to the video player with \u201cControlSend\u201d.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1742 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk15-300x187.jpeg\" alt=\"\" width=\"300\" height=\"187\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk15-300x187.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk15.jpeg 582w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">You can already guess what the previous two macros do. The first one sends the Space key to VLC when pressing F12 (so, it pauses and plays the video). The second one sends Shift+Left to VLC when pressing F11 (it jumps back the video three seconds). Both macros only work from Microsoft Word as they are between the \u201c#IfWinActive\u201d lines.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Why Use Macros?<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">What action needs a macro? If you find yourself hitting the same key or set of keys several times, that could be a macro.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Let\u2019s say you have a subtitle that ends right where the audio ends, and you want to extend it exactly 12 frames (half a second for a 24-fps video), are you going to hit your shortcut 12 times to move the out-cue? No! You could create a macro.<\/span><\/p>\n<p><img decoding=\"async\" loading=\"lazy\" class=\"size-medium wp-image-1743 alignnone\" src=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk16-300x123.jpeg\" alt=\"\" width=\"300\" height=\"123\" srcset=\"https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk16-300x123.jpeg 300w, https:\/\/www.ata-divisions.org\/AVD\/wp-content\/uploads\/2023\/10\/hk16.jpeg 587w\" sizes=\"(max-width: 300px) 100vw, 300px\" \/><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">In this example, the macro is assigned to Shift+F12 (\u201c+F12::\u201d). The \u201cLoop\u201d command repeats an action, in this case, 12 times. The curly brackets are optional in this case, as there is only one line between them. This macro hits \u201cShift Numpad Plus\u201d (with \u201c+{NumpadAdd}\u201d), which is the shortcut in EZTitles to move the out-cue one frame to the right. Of course, if you use a different shortcut, you should replace this line with your own.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><strong><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Many More Things to Do<\/span><\/strong><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">This is all the space we have for now. There are some other easy macros you can try to create yourself, for example, adding dialogue hyphens to both lines, or adding music symbols to the start and end of a subtitle (and even italicizing the text in between the music symbols).<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">The next time you start using a new subtitling system, instead of learning new shortcuts, you could use 30 minutes to prepare a new AHK file. It will save you a lot of time later.<\/span><\/p>\n<p class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Other macros will require doing some actual programming. Let\u2019s say your system doesn\u2019t have two basic functions such as \u201cmove word down\/up\u201d, which are used to change line breaks swiftly. This is doable, but beyond the extent of this introductory article. I hope you can start using macros soon and that they save you as much time as they do for me.<\/span><\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<h5 class=\"cvGsUA direction-ltr align-start para-style-title\"><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Adri\u00e1n Bergonzi<\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\"> is an Argentine English&lt;&gt;Spanish <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">translator <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">and <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">programmer. <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">He has <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">nine years <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">of experience <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">in audiovisual <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">translation <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">and software <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">localization. <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">He works <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">as a freelance <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">subtitle <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">translator <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">for major subtitle localization companies and has translated and proofread many films and series for theatrical release, Blu-ray and streaming. <\/span><span class=\"OYPEnA text-decoration-none text-strikethrough-none\">Contact: <\/span><a class=\"OYPEnA text-decoration-underline text-strikethrough-none\" draggable=\"false\" href=\"mailto:adrianbergonzi@gmail.com\" target=\"_blank\" rel=\"noopener\">adrianbergonzi@gmail.com<\/a><\/h5>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>by Adri\u00e1n Bergonzi A Little History: How I Discovered AutoHotkey It was a long time ago. I had started working for a new subtitling agency and received my first assignment. Every new online system takes some time to get used to. Except this one, where the shortcuts were an absolute nightmare: Enter moved to the [&hellip;]<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"_genesis_hide_title":false,"_genesis_hide_breadcrumbs":false,"_genesis_hide_singular_image":false,"_genesis_hide_footer_widgets":false,"_genesis_custom_body_class":"","_genesis_custom_post_class":"","_genesis_layout":"","footnotes":""},"categories":[588,12],"tags":[596,603,599,239,305,601,598,605,595,602,52,251,457,604,55,597,179,38,600],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/posts\/1726"}],"collection":[{"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/comments?post=1726"}],"version-history":[{"count":2,"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/posts\/1726\/revisions"}],"predecessor-version":[{"id":1746,"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/posts\/1726\/revisions\/1746"}],"wp:attachment":[{"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/media?parent=1726"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/categories?post=1726"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.ata-divisions.org\/AVD\/wp-json\/wp\/v2\/tags?post=1726"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}