I want to do some screencasts and then upload them to Vimeo, which has specifications of resolutions that will yield good results. As such, I would like to be able to accurately and repeatably size the application window I am making a screencast from, to make the best use of that space.
Googling the problem, I came up with answers like this:
tell application "Safari"
activate
set the bounds of the first window to {140, 0, 1160, 775}
end tell
I found that this method works with some applications I tried (such as Opera and Firefox), but not with the two applications I want to make screencasts from.
When I try it with "Scratch" in place of "Safari", I get
AppleScript Error Scratch got an error: Can’t set bounds of window 1 to {140, 0, 1160, 775}.
and, I get a the same error when I use "MINDSTORMS NXT" [the NXT-G programming language for Lego Mindstorms NXT] in place of "Safari" (except for the name of the application that caused the error).
I presume, in both cases, that the error is due to the fact that these are not native (Cocoa) apps, but built using cross-platform libraries. I also read that sometimes changing the window number (ie. "second window", "third window") will help, but it did not.
Now then, I really don't need to know how to do this in AppleScript, I just want a simple way to set the dimensions of a window for screencasting. Anyone have a tip?