Add a Period After Pressing the Spacebar Twice

Typing a period after each sentence is something the computer should do for me. It’s something a Mac will do: I press the spacebar twice and, bam, I get a period. No need to use the stupid “Shift+;” on my azerty keyboard.

Windows 10 can do it too, with a little help.

In the Settings, there is an option to add a period after a double press on the spacebar.

Windows 10 double. space option, you'll find it in Settings->Typing: "Add a period after I double-tap the Spacebar"

But it only works with the software/on-screen keyboard. Not with a physical keyboard.

The best workaround I’ve found is to create a snippet in AutoHotKey. It will work anywhere, no matter the keyboard.

If you’re a Mac user, think of AutoHotKey (AHK, for short) as TextExpander without the pretty interface, but put on steroids (and speed), fast and light, and completely free. It is an amazingly powerful app, if you like using shortcuts to simplify your life.

So, my double-space snippet looks like this:

:*?: ::

send .{space}

Return

It’s not pretty, but it’s simpler than you might think:

  1. The first line says to AHK to listen for a double space trigger: I typed two spaces, between the opening “:*?:”—hey, AHK listen!—and the final “::”.
  2. The second line: if AHK detects this trigger, it must immediately replace the double space I just typed with a period, followed by a space. Why adding a space? Because it saves me the burden of manually typing a space before I begin writing the following sentence 😉
  3. The last line ends this trigger/snippet. It tells AHK to resume listening to whatever trigger I may type after that.

Leave a Reply

Your email address will not be published. Required fields are marked *