Question

When switching to an application (cmd+tab or clicking on an app icon), osx brings all of the application's windows to top.

I would like to trigger this behaviour for the active application with some shortcut, or most preferably triggered when clicking the dock icon of the active application. (Currently clicking on the dock icon of an active app switches to the next workspace that has a window of the app.)

Is there a way to bring to top all windows of the active application?

EDIT: Seems there's a Window -> Bring All to Front action that does this. Now I only need a way to trigger this action, preferably when the app icon in the dock is clicked.

Third party command solutions (e.g. some simple keyboard shortcut app to run the Bring All to Front action) are welcome, though I'd prefer a native way of doing this.

Was it helpful?

Solution

You can assign a keyboard shortcut to the "Bring All to Front" menu item from System Preferences:

The activate AppleScript command also raises all windows:

activate application (path to frontmost application as text)

If you are assigning keyboard shortcuts to opening applications, you can use scripts like this:

tell application "TextEdit"
    reopen
    activate
end tell

reopen opens a new default window if there are no open "default" windows, like a text editor window in TextEdit. If all default windows are minimized, reopen unminimizes one of them.

It is also possible to use AppleScript to click the "Bring All to Front" menu item:

tell application "System Events" to tell (process 1 where frontmost is true)
    click menu item "Bring All to Front" of menu 1 of menu bar item "Window" of menu bar 1
end tell

OTHER TIPS

I use ⌘ Command~ to cycle windows of currently selected application.

MacOS Mojave.

Brining all of an app's windows to the front when clicking a single background window was a behavior of "classic" Mac OS:

http://hypercritical.co/2020/01/08/front-and-center


In classic, when you click on a window that belongs to an application that’s not currently active, all the windows that belong to that application come to the front. In Mac OS X (and macOS), only the window that you click comes to the front.

My particular style of window management leans heavily on the classic behavior. I also appreciate the Mac OS X behavior in certain circumstances, so I was delighted to find apps that enable both behaviors, using Shift-click to override the default.

Sadly, macOS Catalina’s lack of support for 32-bit apps finally killed the last of the apps that implemented this feature. I was alone in a cold, barren world where I had to click on a Dock icon to switch to an app and bring all its windows to the front.


Siracusa released a 64-bit app, Front and Center, to bring the "classic" behavior to modern versions of macOS that dropped 32-bit support.

https://apps.apple.com/us/app/front-and-center/id1493996622?ls=1&mt=12

Front and Center lets you control the window layering policy on your Mac. In "Classic" mode, clicking on a window brings all the windows in that app to the front, just like it did in classic Mac OS. In "Modern" mode, only the clicked window comes to the front. In either mode, Shift-click on a window to get the opposite of the chosen behavior.

In the interest of internet archaeology I provide this additional information:

Back in the OS X 10.4 "Tiger" days there used to be a PowerPC-only program called "Application Switcher Menu" (ASM) that was hosted at the now defunct http://www.vercruesse.de/software and had the ability to bring all windows of an application to the front when any individual window was brought forward. The source code for that application was eventually published by the creator, which allowed a free successor program to be created; multiXFinder. It too was PPC-only.

For Intel-based Macs, some currently available commercial choices include DragThing by James Thomson (that works up through OS X 10.12 Sierra at least) and SuperTab by SpriTec Software (untested by me but the homepage claims it's compatible through 10.13 High Sierra). Both of these products include a "bring all application windows to the front" feature that is tangential to their primary purposes.

Licensed under: CC-BY-SA with attribution
Not affiliated with apple.stackexchange
scroll top