Dismissing macOS modal dialogs

Software

There’s a macOS convention that pressing Command along with the first letter of a push button will press it. This is most useful for quickly dismissing Save dialog boxes for documents I want to discard.

Screenshot from Outlook for Mac showing a save dialog box above a new email.

In the above screenshot, I activated the modal dialog with Command+W, to close the window. Pressing Command+D here presses the “Discard Changes” button, which means my fingers haven’t left the keyboard to close this window.

Unfortunately, support for this time-saving convention is patchy, with even some of Apple’s own tools ignoring it. The following require a trip to the mouse to dismiss their dialog boxes:

  • Apple TextEdit.app
  • Mozilla Thunderbird
  • More I’m blanking on right now

As much as I’ve begrudgingly switched to Outlook for $reasons, being able to dismiss dialog boxes with the keyboard has already made me far more productive. If you’re a macOS developer, please implement this.

Author bio and support

Me!

Ruben Schade is a technical writer and IaaS engineer in Sydney, Australia who refers to himself in the third person in bios. Wait, not BIOS… my brain should be EFI by now.

The site is powered by Hugo, FreeBSD, and OpenZFS on OrionVM, everyone’s favourite cloud infrastructure provider.

If you found this post helpful or entertaining, you can shout me a coffee or buy some silly merch. Thanks!