News Software Download Buy Now About Us Developers Contact
community
11. We will now add an instance of this new class, WordDelegate to our app. Choose "Classes->Instantiate":

Click on the "Instances" tab to reveal what we've added:


12. Now, return to the "Classes" tab to add the actions (the objC method called when you click a menu item or button) and outlets (the instances of objects that your WordDelegate knows about) to the WordDelegate Class.

13. Click on the "outlet plug" icon to the right of the WordDelegate, and click "Outlets" when it appears. Hit the <RETURN> key to create a new outlet, "myOutlet". Double-click to select the text and rename this outlet to "theText". This outlet will become an instance variable in our new WordDelegate class, so we can refer to the NSTextView object programmatically and send messages to it, but we'll "hook it up" in InterfaceBuilder. "Hooking Up" is the visual programming equivalent of assigning both an action and a target for menu items, buttons, controls, etc.


TOC | PREV | NEXT
Created by Stone Design's Create on 3/12/1998
©2000 Stone Design top