Changing MacOS Desktop Background Colors With Keyboard Maestro

Introduction

On my Apple MacOS, I prefer to use solid colors for my desktop backgrounds instead of pictures. There’s a few reasons for this.

First, and primarily, I record training videos for Pluralsight. Having a solid color for a background eliminates any visual distractions for the viewers.

Second, using a solid color provides a visual queue to which desktop space I’m working in. My previous post Moving Between Multiple MacOS Desktop Spaces With Keyboard Maestro, I documented how I like to have multiple spaces across my three external monitors. The first space for business apps, second for coding, and final space for video recording or other tasks.

I’ve noticed that when I first boot my MacBook, it doesn’t always restore the same colors I had when I shut down. One monitor might have a blue background, another might be dark gray. This happens often enough to be annoying, and something I want to easily correct.

There are also times when I’m working under different lighting conditions than normal, and a darker black background, or a very light gray may work better. Having the ability to change this easily was important to me.

If you read my last few posts, you saw how powerful Keyboard Maestro | @KeyboardMaestro is. So I turned to it and was happy to say I found a solution, although I admit it’s a bit of a workaround.

Before we get started, be aware Keyboard Maestro is a paid app. However it’s a one time purchase of only $36 (US). Well worth the investment for everything it does.

Additionally, this won’t be a step by step tutorial on how to use Keyboard Maestro. The Keyboard Maestro website, YouTube, and the internet have a plethora of those on the basic use of the Keyboard Maestro application. This post will focus on the solution I came up with.

OK, let’s go see how to add some color to our lives!

Setting The Background

Before you can proceed, you will first need a transparent PNG file. You can create your own, or grab one from the web. I found one at Wikimedia Commons. You can download the smallest size, then save it to your Documents folder (or some other common location, I went with Documents).

Next, start a new macro. I chose to bind this first one to Ctrl+Option+Shift+G, as I’ll be using it for a Gray background.

Next, add an action of Set Desktop Image. For the image file, select the transparent PNG file you created (or downloaded).

Set it to Fit to screen, then set the background to the color you want. In the image below, I chose a dark gray color.

Now you can repeat this, adding additional macros for each color you want to add. I have macros for dark gray, green, dark red, blue, and a light gray almost white in color. Normally I use dark gray for my "business" spaces, blue for my development spaces, and dark red or dark green for the third desktop space, depending on my mood. I can also change easily if lighting conditions would make a certain color easier to on my eyes.

As you can see, the workaround is to use a transparent image and set a background color. True, I could manually go set a background color each time directly through the MacOS Change Desktop Background interface, but that’s time consuming compared to a simple key combination.

Using with Pictures Too!

Here I chose a transparent image, but you could if you wished use this with normal pictures. When working from home, you may want a background of your family. At a company meeting, you may want to quickly change this to your company logo. If you are about to do some screen sharing, you may want just a solid background color, like I showed in this post.

Conclusion

This becomes a very handy tool for situations when, upon booting, MacOS doesn’t restore my colors correctly, or for changing them to meet my needs at the moment.

I hope you found this Keyboard Maestro macro to change your desktop background colors as useful as I do. If so, please share this post with your friends, family, and anyone else who uses an Apple Mac product.

Disclaimer, this was in no way a paid advertisement for Keyboard Maestro. I received no compensation for doing this post. In fact I purchased Keyboard Maestro with my own hard earned money. I just think its a great tool and wanted to share this technique to change multiple desktop spaces simultaneously with you.

I record video training courses for Pluralsight, including several on the Apple MacOS platform. You’ll find a list of my courses with links on my About Me page.

If you don’t have a Pluralsight subscription, just go to my list of courses on Pluralsight . At the top is a Try For Free button you can use to get a free 10 day subscription to Pluralsight, with which you can watch my courses, or any other course on the site.

Advertisement

Moving Between Multiple MacOS Desktop Spaces With Keyboard Maestro

Introduction

Like many people, I use Apple’s multiple desktop spaces feature on MacOS. I use the first space for "business". My email reader, to do task list, social media, notes app, and the like goes here.

My second space is used for development. VSCode and related apps go into this spot. My third spot is either used for video recording, or other tasks as needed.

The MacOS spaces feature works in one of two ways. In the older method all desktop spaces were tied together. You used CTRL+Left Arrow or CTRL+Right Arrow to move between them, and the spaces on all monitors changed together. You got one menu bar across the top of the primary monitor.

You can actually change MacOS to revert back to this behavior, but I like having a menu bar on each display so don’t like to use it.

In the current, default mode each monitor has a space that is independent of the others. I can change the current space on one monitor, but the others remain as they were. Each monitor has its own menu bar across the top.

I have three monitors connected to my MacBook, and it can be annoying to have to change the space on each monitor individually, when the majority of the time I want to change them all together. Sadly there is no method built into MacOS to do this.

I finally found a way to accomplish this using Keyboard Maestro | @KeyboardMaestro. Be aware Keyboard Maestro is a paid app, but a one time purchase of only $36 (US). Well worth the investment for everything it does.

Just a preface first, this won’t be a step by step tutorial on how to use Keyboard Maestro. The Keyboard Maestro website, YouTube, and the internet contain a vast collection on the basic use of the Keyboard Maestro application. This post will focus on the solution I came up with.

OK, with that out of the way let’s see how to change desktop spaces simultaneously.

Changing Spaces On All Monitors

Changing the desktop space requires a few steps, as you’ll see in the image below.

In the first action I used Move or Click Mouse and changed it to Move Only, to relocate the mouse to an absolute position on my first monitor. I started with the leftmost monitor in my setup.

You can use the Get button found in the move mouse action to easily capture the coordinates. I just moved the mouse over to the middle of the monitor to grab the position.

Next, I have a Type a Keystroke action, and have it press CTRL+Right Arrow. I then have a Pause action, to make the macro wait one second before proceeding.

I found without the pause, my Mac was running so fast it didn’t have time to figure out where the cursor was before processing the CTRL+Right Arrow keystroke, so it wasn’t always changing the correct monitors desktop space. Adding the Pause fixed this.

For the second monitor I have another Mouse Move (but no click) that just moves the cursor 2000 pixels over from the last mouse position, which was on monitor 1. This is enough to move the mouse over to monitor 2.

I then have another keystroke action to press CTRL+Right Arrow, then another pause. I repeat these steps for the remaining monitors.

I suppose I could have positioned the mouse in an absolute position for all my monitors, but to me this will make the macro easier to reuse in other setups.

At the very end I added a final Mouse Move action to reposition the mouse over the center of my primary monitor. This way I’ll know where it is each time and won’t have to hunt it down.

I tied this macro to CTRL+F12. Now I can move the spaces for all my monitors one screen to the right with one key press.

Moving Left

To move everything back to the left, I duplicated the macro. Then I simply changed all of the keystroke actions to press CTRL+Left Arrow. Finally I bound the macro to CTRL+F11.

Disabling Changing On Some Spaces

If you are familiar with Keyboard Maestro, you may have noticed three actions toward the bottom that are disabled. Originally I had all three external monitors, plus the internal monitor on my MacBook, changing together.

As my MacBook tends to sit off to the side, I primarily use the internal monitor to hold the Apple Messages app in case my wife (aka she-who-must-be-obeyed) sends me a text. It lets me notice and respond quickly.

I also leave the Apple Home app on this monitor so I can turn the lights and fans in my house on and off easily. When I play music the Apple Music app sits here too. I opted to disable desktop space changing on this monitor, although I left the actions in the macro but disabled in case I should ever want to turn them back on.

It also serves as an example that you can opt to change some, but not all, desktop spaces at the same time.

Don’t Go Too Fast

Be aware you need to give Keyboard Maestro time to process the macro. You cannot rapidly press CTRL+F12 CTRL+F12 CTRL+F12… quickly and have the macro work right.

It’s best to press the activation keystroke (CTRL+F12 in my case), let go of the keyboard until all the spaces have changed, then press it again.

Even with that slight limitation, it is still far faster than having to move your mouse to each monitor and use the built in CTRL+Left/Right arrow keystrokes.

Also be aware I chose CTRL+F12 and CTRL+F11 for my activation keystrokes. You are free to pick any key combination that is not currently in use on your Mac.

Conclusion

I hope you’ll find this Keyboard Maestro macro as useful as I do. If so, please share this post with your friends, family, and anyone else who uses an Apple Mac product.

Disclaimer, this was in no way a paid advertisement for Keyboard Maestro. I received no compensation for doing this post. In fact I purchased Keyboard Maestro with my own hard earned money. I just think its a great tool and wanted to share this technique to change multiple desktop spaces simultaneously with you.

I record video training courses for Pluralsight, including several on the Apple MacOS platform. You’ll find a list of my courses with links on my About Me page.

If you don’t have a Pluralsight subscription, just go to my list of courses on Pluralsight . At the top is a Try For Free button you can use to get a free 10 day subscription to Pluralsight, with which you can watch my courses, or any other course on the site.

Opening Multiple Apps on MacOS With Keyboard Maestro

Introduction

When I sit down at my Apple MacBook to begin my workday, there are a variety of apps I open and use daily. I also use multiple monitors, so I can spread my work out. When done manually, this required me to open each app, move it to the monitor I wanted, then repeat. Very time consuming.

I wanted a way to automate this, and found Keyboard Maestro | @KeyboardMaestro to be the best solution. It was easy to setup, and I could trigger things off a simple keyboard combination.

Be aware Keyboard Maestro is a paid app, but a one time purchase of only $36 (US). Well worth the investment for everything it does.

Just a preface, this won’t be a step by step tutorial on how to use Keyboard Maestro. The Keyboard Maestro website, YouTube, and the internet have a plethora of those on the basic use of the Keyboard Maestro application. This post will focus on the solution I came up with.

OK, that said let’s see how to open multiple apps.

Opening and Positioning an App

Opening an app in Keyboard Maestro requires three basic steps. First, use the Activate Application action. This will open the app if it’s not already open, or bring it to the foreground if it’s open already. If you’ve already got the app open when you create the action, you can easily pick it in the Activate action’s app picker list inside the Keyboard Maestro editor.

Next, you need a Pause action. This is needed to give the app time to fully open before you attempt to move it in the next step. For most apps around 3 seconds was sufficient. Some apps loaded quickly, and I could reduce the pause time to one or two seconds. A few I had to bump up to four or five seconds. You’ll just have to play with this, as it is quite dependant on the app, the speed of your Mac, and even the internet for apps that require access to the web.

Finally I added a Move Window action, then changed it to Move and Resize Front Window. You can manually enter the top corner coordinates, followed by the width and height.

Far easier though is to have the app positioned where you want it, then use the Get button, found in the Move and Resize Front Window action. This turns the mouse into cross hairs, and you have five seconds to draw a box around the app. This will get the coordinates and paste them into the action. From there you can make any minor tweaks.

Now, repeat! Repeat these three steps for each application you want to open. Here is a screen shot of my list.

There’s one more action, just off the bottom of the screen, a Move Mouse action.

After opening up my apps I wanted to position the mouse in a spot where I knew it would be.

IMPORTANT!!! Keep Your Hands Off The Keyboard and Mouse!!!

One important thing, make sure not to touch the keyboard or mouse while these macros are running. Otherwise you might interrupt the workflow and apps won’t open correctly or may not be where you want them positioned.

Of course if that happens its not a big deal, you can just run the macro a second time to get everything positioned right, but best not to waste the time if you can avoid it.

Variations

This app saves me a lot of time every day. I carry my MacBook onto a sunroom / porch I have on the back of my house, plug it in to my monitors (don’t worry the sunroom is secure), and run the Keyboard Maestro macro. Sure, it takes about a minute to run and open everything, but that is far faster than doing it manually. In addition I can do other tasks while it is running, such as plugging in my iPads and setting them on my desk, or sitting my Windows / Linux laptop in its docking station.

Because this is tied to a keyboard combination, I can have multiple versions. For the sunroom I enjoy working on I use Ctrl+Shift+Option+Cmd+P to start my work day. In addition to the sunroom, I also have an actual home office where Ctrl+Shift+Option+Cmd+O opens and positions everything. In addition, my in-laws kindly gave me a corner in a spare room to setup a small desk with some monitors so I can work when we visit there, using Ctrl+Shift+Option+Cmd+D. (D is the first letter of the town they live in, in case you were wondering.)

Finally I have yet a fourth version to open my apps when I am using only the internal monitor of my MacBook, with no external monitors attached. For it I use Ctrl+Shift+Option+Cmd+L (L for Laptop Only).

During the course of the day I’ll wind up moving applications around on the screen, dragging between monitors, and the like. At some point I like to refresh everything to put my apps back where I had them at the start of the day. I can of course run the full Ctrl+Shift+Option+Cmd+P (for example) and it works just fine.

However, if I know all the apps are already open, there is no sense in giving each one time to open. So I created a duplicate of the original macro, and simply removed all of the pause actions. I then use Ctrl+Option+Cmd+P to activate it. I did the same for the other macros, creating a version without the pause, and the only difference being the faster (much faster!) version doesn’t include Shift as part of the activation.

Thanks to MacGeekGab

I need to give a shout out to my favorite Apple podcast Mac Geek Gab | @MacGeekGab. In a past episode one of the hosts (I believe it was Dave) mentioned using Keyboard Maestro to do this very thing, although didn’t go into any details.

That gave me the inspiration to tackle this challenge. Through some trial and error, along with persistance, I was able to come up with a solution that worked for me.

Conclusion

If you are an Apple Mac user and don’t have Keyboard Maestro, it is a worth while investment. As a matter of fact, I have some upcoming posts in which I’ll document a few other things I use it for!

The same goes for Mac Geek Gab, if you aren’t listening to their podcast, you should!

Disclaimer, this was in no way a paid advertisement from either Keyboard Maestro or Mac Geek Gab. I received no compensation for doing this post. In fact I purchased Keyboard Maestro with my own hard earned money, and even donate to Mac Geek Gab. I just think they are both great tools and wanted to share them with you.

I record video training courses for Pluralsight, including several on the Apple MacOS platform. You’ll find a list of my courses with links on my About Me page.

If you don’t have a Pluralsight subscription, just go to my list of courses on Pluralsight . At the top is a Try For Free button you can use to get a free 10 day subscription to Pluralsight, with which you can watch my courses, or any other course on the site.