Louis-Philippe wrote:

> I am looking around and I can't find docs about GUI scripting from the
> Scripting Bridge...  it seems like NSAppleScript would do it, but I would
> like it better if I could do it with objective-c logic.  Anybody has worked
> around something like that?

Given that GUI scripting is inherently nasty and fragile, and prone to breaking 
whenever target applications are updated, I'd personally keep that code as 
compiled AppleScripts (.scpt files) stored within the .app bundle for ease of 
maintenance. 

Alternatively, if you really want to use [Obj]C, you could cut out 
AppleScript/System Events entirely and just talk directly to Mac OS X's 
Accessibility APIs (which is what System Events does).

Or, you could always try poking the developer of the target application to 
provide some sort of externally accessible API (Apple events/Distributed 
Objects/SOAP/sockets/shared framework/whatever) and avoid all that nastiness 
entirely. That would be the best solution, of course.

HTH

has
-- 
Control AppleScriptable applications from Python, Ruby and ObjC:
http://appscript.sourceforge.net

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to