Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Scripting Capture of an Internet Connect Window?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scripting Capture of an Internet Connect Window?



On 2006-10-23, at 20:09:56, Jonathan Levi, M.D. wrote:

Hi, -- I'd like to do the above, preferably using Grab (which is "not scriptable") or automating a command-function-3 keypress. Problems are that GUI-scripting Grab seems to lead in the end to a need for an actual mouse click -- "click {x,y}" does nothing, even though x and y are global coordinates inside the Internet Connect window. Or I could capture the whole screen with command- function-3, then cut the picture down to the area that I want pretty easily, but I don't know how to automate typing command- function-3. Any ideas? --TIA, Jonathan

You can get the whole screen with:

do shell script "screencapture -w ~/Desktop/screen.png"

and then use this tool to crop it:

<http://homepage.mac.com/philip_aker/dl/tools/pngcrop100.zip>

So maybe use GUI scripting to get your window's position and size to feed into pngcrop.

Philip Aker
email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. AppleScript-Users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: Archives: http://lists.apple.com/mailman//archives/applescript-users

This email sent to email@hidden
References: 
 >Scripting Capture of an Internet Connect Window? (From: "Jonathan Levi, M.D." <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.