• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: scriptability of button in interface?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: scriptability of button in interface?


  • Subject: Re: scriptability of button in interface?
  • From: Uli Kusterer <email@hidden>
  • Date: Sat, 3 May 2008 13:07:04 +0200

Am 03.05.2008 um 12:09 schrieb Patrick J. Collins:
I am assuming there is something in interface builder that you need to do to
accomplish this, but I just don't know what it is.


No, not in IB. AppleScript in general doesn't script the UI, but rather what is the controller layer in a Cocoa app. So, what you need to do is create a scripting definition (.sdef and stuff like that) that maps AppleScript command names to methods on your controller object. http://developer.apple.com has some nice documentation on making Cocoa applications scriptable this way, using NSScriptCommand where you need to add your own commands that don't have objects associated with them.

Cheers,
-- Uli Kusterer
"The Witnesses of TeachText are everywhere..."
http://www.zathras.de





_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:
This email sent to email@hidden


References: 
 >scriptability of button in interface? (From: "Patrick J. Collins" <email@hidden>)

  • Prev by Date: Re: Loading a .nib?
  • Next by Date: Re: drawing in a separate thread
  • Previous by thread: scriptability of button in interface?
  • Next by thread: NSImageView blocking drag
  • Index(es):
    • Date
    • Thread