forcontent.blogg.se

Quicktime player for mac how to pause screen recording
Quicktime player for mac how to pause screen recording







Also, I didn't code in any way to stop recording (though that would be easy enough: just click the button without the controlKeyEvent call). I think I can tweak that so that the keypress event goes straight to the Player app, but I have to look into it. Right now, Quicktime Player needs to be in the foreground to catch the keypress event, otherwise pausing won't work. TheEvent = CGEventCreateKeyboardEvent(None, ke圜ode, isKeyDown) If description of actionButton is in thenĮlse if description of actionButton is "stop recording" thenįrom Quartz.CoreGraphics import CGEventCreateKeyboardEventįrom Quartz.CoreGraphics import CGEventCreateįrom Quartz.CoreGraphics import CGEventPostįrom Quartz.CoreGraphics import kCGHIDEventTap Set actionButton to first button whose description is "stop recording" or description is "start recording" or description is "resume recording" tell application "QuickTime Player" to activate

quicktime player for mac how to pause screen recording

See this StackOverflow answer for details: I just discovered that PyObjc 2.5 is installed on OSX by default, and that should be more than sufficient for this purpose. This uses python to simulate option-key presses (holding down the option key turns the 'stop' button into a 'pause' button), so you may need to install python's Objective-C packages. If an Audio Recording window is open, this script will start or resume recording if recording is paused, and pause recording if it isn't. Ok, I dug into this a bit and came up with the following script.









Quicktime player for mac how to pause screen recording