I've been searching for a good applescript to automatically change my resolution based on my power source and/or shortcuts. For context I'm using macOS Ventura 13.4 and I'm new to scripting, I want to setup a script to change my resolution from 1710 x 1112 when I'm on battery, to 2560 x 1664 when I'm connected to power. I have found a way to activate the script when changing power sources courtesy of this. Now I just need the script. Please let me know if you have any ideas.
-
See the answers in the two questions linked on top. It actually might be easier to use one of the specific utilities than to script System Settings.– nohillside ♦Commented Aug 8, 2023 at 17:38
-
I don't understand the edit. As you wrote, you already know how to trigger a command if the power source changes, so the missing piece is code to actually change resolutions. This is covered in the answers to the two existing questions linked above.– nohillside ♦Commented Aug 8, 2023 at 18:18
-
@nohillside the code is limited to the default resolution options. Default, Larger text, more Space etc. But I want to set the resolution to 2560 x 1664 specifically which is buried under the toggle (Show all resolutions)– Atharv TandaleCommented Aug 8, 2023 at 18:22
-
Please look at the existing answers, some of them should allow to select any resolution.– nohillside ♦Commented Aug 9, 2023 at 5:14
Add a comment
|