-5.8 C
United States of America
Wednesday, January 8, 2025

areas – Are you able to COMPLETELY disable desktop switching animation on macOS?


I do know this query has already been answered and been accepted however I simply needed to share a few of my findings about this matter. The issue I confronted with the accepted reply was that with Mission Management => Shows have separate areas set, the above habits didn’t work like native macOS and as a substitute cycled via the areas with out respecting which monitor that house is on. If you’re studying this, which means this drawback actually pisses you off so… right here is my answer.

My machine – Macbook Professional 16″ Intel 2019 macOS Monterey However answer ought to work on M collection Macbooks as nicely so long as yabai runs nice.

Drawback

macOS areas change animation when carried out by way of keyboard shortcuts ctrl+proper/left could be very gradual and it feels fairly annoying as a result of it additionally drastically reduces the time to focus. There isn’t any native option to eliminate this delayed animation.

Resolution

We are able to use a software known as Yabai at the side of a software like Higher Contact Device to repair this drawback with the next steps.

Config

My /Customers/akay64/.yabairc file contents, I do not want another configs from Yabai or the tiling window supervisor so my config file is naked bones.

#!/usr/bin/env sh

#
# for this to work it's essential to configure sudo such that
# it is going to be capable of run the command with out password
#
# see this wiki web page for info:
#  - https://github.com/koekeishiya/yabai/wiki/Putting in-yabai-(latest-release)#configure-scripting-addition
#
yabai -m sign --add occasion=dock_did_restart motion="sudo yabai --load-sa"
sudo yabai --load-sa

Scripting

Now go to Higher Contact Device and create a brand new keyboard shortcut for transferring to the left house, decide motion “Execute terminal command (Async)” and have it run this script.

/usr/native/bin/yabai -m house --focus $(/usr/native/bin/yabai -m question --spaces --display mouse | /Customers/akay64/standalone/jq ".[].index" | grep $((`/usr/native/bin/yabai -m question --spaces --space mouse | /Customers/akay64/standalone/jq ".index"` - 1)))

enter image description here

Now do the identical for transferring to the fitting house and provides it this script to run

/usr/native/bin/yabai -m house --focus $(/usr/native/bin/yabai -m question --spaces --display mouse | /Customers/akay64/standalone/jq ".[].index" | grep $((1 + `/usr/native/bin/yabai -m question --spaces --space mouse | /Customers/akay64/standalone/jq ".index"`)))

enter image description here

At this level this keyboard quick reduce may be sure to another enter software, in my case I favor to bind it to my mouse buttons.

enter image description here

What is that this script doing?

  1. Will get all of the areas of the present show underneath your mouse cursor
  2. Will get the index of the present house underneath your mouse cursor
  3. Finds the +1 or -1 (subsequent or earlier) house indexes for the present show
  4. Passes the discovered index to the house --focus command to maneuver focus to

This method permits us to copy the default macOS habits (sans the animation) of solely having the ability to change the house of the monitor your mouse it at present at somewhat than biking via all of the areas whatever the monitor.

Related Articles

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Latest Articles