Is there any way to have OS X's Automator.app repeatedly take screen shots of a book in Adobe Digital Editions? So me doing the task involves:
- Cmd + Shift + 4
- space bar
- mouse click
- page down
Can this be automated?
Yes, this is possible.
You can use with Script Editor.app or Automator.app for your task. If you choose Automator.app, using the Run AppleScript action to embed your AppleScript snippets.
Take a look at using AppleScript to automate key presses, How do I automate a key press in AppleScript? An example from the top answer:
delay 0.5 -- time to release modifier keys if for example the script is run with command-R tell application "System Events" to tell process "Adobe Digital Editions" try key down option delay 0.1 click menu bar item 1 of menu bar 1 end try key up option end tell
To take a screen shot, there are numerous approaches. This question is a good starting point, Take a screen shot and save to desktop with current time as the name:
set theDesktop to POSIX path of (path to desktop as string) set theCurrentDate to current date set shellCommand to "/usr/sbin/screencapture " & quoted form of (theDesktop & "Screen Shot" & theCurrentDate & ".png") do shell script shellCommand
Simulating the mouse is trickier but likely possible, see Is there a way to simulate a mouse click anywhere on a screen in Dictate ?. AppleScript's GUI scripting is designed to interact with specific elements on the screen.
Please do not use this process to bypass copyright protection.