Move and Resize Windows Works Sporadically, One Step at a Time

I'd like to make use of Move and Resize windows a lot. So I include them in most of my shortcuts.

They work maybe ~60% of the time on the first try, but always work to some degree, and always work completely if I run them enough times. So now all my shortcuts have

-Move and resize
-Wait 3 seconds
-Move and resize (again)
-Wait 3 seconds
-Move and resize (again)

I typically use the built-in "Right / Left Column" like this

Occasionally I'll create one like this:

The moving and resizing happen independently, often taking ~3 tries.
Run once - window resizes
Run again - window moves
Run again - window resizes

Then I restart the target app and it works on the first run.

  • I know about the importance of building in pauses.
  • it's not app specific, it fails sometimes with every app.

I wonder if it has to do with the fact that I am screen mirroring from my laptop? I use an external display and keep the other one fully dimmed (because clamshell kills TrueTone)

I might be imagining this, but apps that seem to tax the windowserver process are perhaps more likely to require multiple runs. Calendar, for example, I don't remember ever failing. But when I have 3 omnifocus windows + obsidian rendering dataviews + safari all floating around, those apps are less likely to snap-to on the first time.

Any help appreciate, thank you!

Howdy, welcome to the forum! As you might have already figured out, this is a great community full of people who love to help.

Without delving too deeply into the issue just yet... in the second screenshot you have a space behind the 70% that shouldn’t be there. Remove that and see if the issue persists.

On another note, if possible, post the macro itself (not just screenshots) so we can take a look at it and see what might be going wrong. As one of the moderators likes to say, "If we're not testing we're guessing, and guessing often wastes people's valuable time". :laughing: If you need help on how to post the macro, just let us know and we can walk you through it.

If you haven’t had the opportunity to read this tutorial, I highly recommend it. It will help you get the most help for your question.

Tip: How Do I Get The Best Answer in the Shortest Time?


Thanks for super fast response. I'll re-examine that percentage.

Ok here's my One-trigger, one-action macro called Full Screen.

Full Screen.kmmacros (2.1 KB)

And here's a video of it in action. Even in this example, it takes a varying number of runs to get where I want it to go.

Video Link

aHA! Thanks for posting the macro and the video. I know exactly what you're talking about now. Unfortunately I don't have an answer for it. I experienced the same issue back in august and brought it up in two different topics.

Prompt for User Input Window Not Appearing Even Though It Is Triggered

Possible Bug: Manipulate a Window Interacts Differently (And Unreliably) With Different Applications

I believe that in my case it had to do with another window management application I was using at the time, which I stopped using. I no longer have the issue. Do you use any other window management software, like Magnet, Rectangle or the like?

Something very odd is going on. I just downloaded your Macro and on my System it works in one go - not in the multiple steps, as in your Video. I have a vague memory that when I've had something similar in the past (Macros going slow or not completing all their steps) a restart has fixed it. But you must have already tried that. I wonder if something else you are running is using up lots of memory or something.

One thing you could try - restart the Mac and double-check that no Apps are running. Then try running your Macro in the Finder.

EDIT - another thing to try is assigning a completely different hot key and see if that makes any difference - in fact, try running the Macro from within Keyboard Maestro by pressing the "Run" button and let it make the Keyboard Maestro Window fill the screen.

BTW it's a small point, but your Macro is Maximising the Window, which as @cdthomer has mentioned is different to making it Full Screen. Like him, I never use Full Screen, I'm too stuck in my Mac ways of dragging things between a jumble of multiple open Windows and feel kind of trapped when an App goes into Full Screen mode and I can't drag its Window around :flushed:.

1 Like

I have BetterTouchTool. I tried quitting it. Not a fix.
I run Catalina on a 2020 Macbook Air i7, 16GB ram. Keep it lean - not many helper apps or extensions or programs at launch.

Restarts of the problem apps fix it, I don't have to restart my computer. But it shows up everyday in several apps, and has for months.

Re: Your suggestion to try it in KM.
KM wasn't having the same problem (it's app-dependent). So instead I removed the hot key and changed it to "Wait 5 seconds THEN manipulate front window", so that I could click run, click over to (safari this time). Still didn't work.

I also tried other hotkeys, no fix.

Also there are no other macros running in the background.

Also I tried quitting (most) other apps, and everything in the menu bar, just to free up memory and CPU. CPU is 80% Idle. Memory is only half used. It still wont do what I want with that finder window!

That is two bits of interesting information. It works on the KM Window. And restarting the problem Apps works in them too (for a bit).

And I can throw in that it should work in all Apps.

What are the “problem Apps”? Hopefully not all Apps apart from KM.

It changes. Right now the finder and Safari are showing the problem, but Obsidian isn't, Omnifocus isn't. But often they do too.

It varies among apps and "number of runs" but never fixes itself once it starts. This finder window, for example, from the video, is 100% reproducible. I've done it over and over. It never goes Max Screen on the first try.

Long shot, but something I've googled and tried to fix a dozen times is my WindowServer process and how much CPU and ram it consumes. I think it has to do with Night Shift and True Tone. And Night Shift requires Wifi to be on...

My pretty-brand-new computer gets really slow, a lot, and it's often WindowServer going crazy. Like right now, I have safari open and activity monitor open and nothing else. WindowServer is winding up and down from 10-40% cpu. And steady 800Mb of ram consumed.

I've tried connecting the monitor via HDMI and Displayport, tried multiple dongles, multiple monitors. My 2015 Macbook Air running Mojave felt 10x snappier.

This sounds VERY weird. My wife has the same computer (I'm on it right now actually :grin:), 2020 MacBook Air, 16GB RAM. CPU usage is NEVER that high for me with only those apps open.

I know this might sound crazy...but have you tried reinstalling the OS?

Like start from scratch as a new user and move files over? I haven't done a completely clean OS install like that in a decade.. Because I got burned bad when I did. So many permissions broke, keychain, icloud. It was a disaster. So when its time for a new computer or OS, I begrudgingly use migration assistant.

It's buggy for sure...

Accountsd or Trustd. I had to quit letting my iphone and ipad connect automatically with mac. I have KM automatically quit every hour or so, I daren't leave it running in the background!

I have this fun bug, Spotlight / MDS makes hundreds of thousands of blank directories, so Time Machine requires 100% cpu. I have to run that manually.

Omnifocus hangs and needs a force restart daily (their tech support couldn't figure it out). Devonthink doesn't sync automatically... Earlier this year Photos decided to delete its entire library...

I just want to take plaintext notes, check email, and browse the web! :weary: (with a little icloud sync now and then)

Hey James,


If you haven't already – please take time to complain loudly to Apple – not enough people do...

Feedback - macOS - Apple


No, not a completely clean install. Just reinstalling the OS. It’s really easy, takes an hour or two at most (depending mainly on what kind of drive, the SSD on the MacBook is so fast it would probably take less than an hour), requires virtually no input from you and preserves all your apps, files and settings. Because all of those issues are definitely not normal.

How to reinstall macOS

Thanks. When Photos literally erased its entire library (and then somehow propagated that bug through 2 backups), I was on the phone with apple for 2 hours. To their credit, and maybe because I did a good job preserving the scene of the crime, they passed me all the way up to the Photos developers. In the end "sounds like it was corrupt... see ya!" :grimacing:

@cdthomer I have installed Catalina more than once in that manner on this machine, hoping to fix some of these bugs. I run EtreCheck and Onyx regularly. I've used an Apple/Mac since the 80s but these past ~5 years or so, chasing bugs has become a part time job. But hey my iPad works great!

Haha. Thanks for allowing me to vent, ya'll.

Any reason you’re still running Catalina and not Big Sur or Monterey?

I HATED Catalina, mainly because of the random audio disconnect issues but for other reasons too.

1 Like

I have audio-via-airplay problems too, I use a KM shortcut to reset audio output source ~ 5x/day.

I haven't heard rave reviews about Big Sur or Monterey. I'd go back to Mojave if I thought I could without breaking more stuff. I just don't have faith in the newer stuff. Even APFS makes me nervous, and (I could be mistaken) doesn't Time Machine start abandoning HFS+ after Catalina?

I did order an M1 Mac Mini and put Monterey on it for a day or two. That was the day my Photos library self destructed. Probably not related, but with so much going on under the hood, who knows. I sent it back.

I didn’t hear rave reviews about Big Sur either but it has been incredibly stable for me with the exception of iCloud Drive (which has been a problem for years apparently and I have finally completely abandoned). Monterey was a disaster on my iMac so I rolled it back to Big Sur for the time being.

EDIT: Not enough brain power to distinguish between Catalina and Monterey apparently... thanks @ccstone :laughing:

Forward you mean?  :sunglasses:

1 Like

HAHA! Yea.... I meant Monterey... it's been a long day :laughing:

1 Like

Sounds like moving windows around with Keyboard Maestro is the absolute least of your problems. To be honest I’m amazed the Macro runs at all with all that other stuff going on :joy:

With all the problems you’ve listed it sounds like you must have reached the end of any road of annoyances. But forgetting about mending any of that for a moment - I have one bit of advice for you:

Make your next project to methodically back up all your Photos and Data and Contact Addresses and emails and Photoshop Templates and Keyboard Maestro Macros and Excel or Numbers Spreadsheets and Passwords etc etc onto external hard disks. And keep thinking of anything else you might need to back up - imagining that your MacBook Air was run over by a truck and you suddenly hadn’t got any Mac at all and had to start from scratch.

And I don’t count Time Machine as a backup in this sense. It’s still a proprietary Mac file that could get corrupted. I mean manually copying files and folders.

And this is a real project that will take more than one day and involve ticking off things on an actual pen and paper list. (In other words - it’s the really fun sort of computer task where you’re doing something fairly simple but it counts as important work :rofl:).

And regarding the Mac Photos Library. As well as making a backup of the Photos Library File I make sure I have copies of the original Photo Files saved outside of the Photos Library itself. Digital Photos and Home Videos are one of the most precious kinds of data, as they are unique moments in time that are impossible to recreate if they are lost. (The simplest way to back them up is to use the Photos "export originals" menu option and save them direct to an external hard drive - make sure to have Photos "use original name" for the export otherwise the exported versions will have long meaningless numbers as their names.)

After you’ve backed up everything - make exact copies of those backup hard drives and give those copies to a friend so there are copies away from your house.

Don’t do any more tinkering until you have at least 1) The complete backup of everything that is unique to you and preferably, 2) a brand new unused Mac to start fresh on.

When you get another new Mac don’t initially change any of its default settings. Sign into iCloud. Let that copy over your addresses and email settings.

Then manually reinstall your third party software and manually copy over your data. (I’ve never used Migration Assistant.) That way you are not copying over the problems that you are experiencing on your current Mac onto your new Mac. Once you are happy the new Mac is working fine and there is no data remaining on your old MacBook Air - you can wipe the MacBook Air and treat it like a new Mac and hopefully leave all the problems you have listed behind. And - best of all - your Keyboard Maestro Macro should happily maximise any window in one instant step :grinning:

Moving forward:

I have come to rely on a lot of Cloud based syncing Apps - iCloud Calendars/Contacts, Dropbox, iCloud Photos and as of now they are all working and making my life easier. It sounds like you have been very unlucky - Migration Assistant (although I haven’t ever used it) should work and not cause the problems you are experiencing.