• 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: IB does not show Outlet/Action section in inspector
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: IB does not show Outlet/Action section in inspector


  • Subject: Re: IB does not show Outlet/Action section in inspector
  • From: Bill Cheeseman <email@hidden>
  • Date: Wed, 23 Sep 2009 09:26:05 -0400


On Sep 23, 2009, at 7:11 AM, Gregory Weston wrote:

There is no mechanism in the current version of the tools for defining outlets and actions in IB; only for assigning them.

I don't believe this statement is true, if I understand your point correctly. Here's how to create an outlet or an action in IB 3.2 and write it back to your source files. You can also create wholly new classes this way.


1. In any of your project's nib files, go to the Library window (not the Inspector window) and select the Classes tab. Using the pop-up menu at the top, select one of your project's classes in the very long and awkward hierarchical menu. For example, your class MyDocument would appear in the menu under NSDocument if it inherits from NSDocument.

2. In the bottom pane, select the Outlets or Actions tab.

3. Near the bottom of the window, click the Add (+) button. Type a name for the new outlet or action and a return type (which should be void for actions).

4. At the bottom of the window, use the Action button and choose Write Updated Class Files.

5. In the dialog that comes up, choose to save the file to the original name for the implementation file.

6. In the warning alert that comes up to tell you that file already exists, choose Replace to incorporate your new outlet or action in the existing file, or Merge to bring up FileMerge and give yourself a chance to accept or reject individual changes.

7. Lock at your header file. The new outlet or action is right there. (The setter and getter methods or properties for outlets are not produced by this technique, however.) Look at your implementation file. If you created an action, a stub method definition appears.

Is this less than what you used to be able to do in IB? To the best of my memory, it gives you more control over what is produced.


--

Bill Cheeseman
email@hidden

_______________________________________________

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


  • Follow-Ups:
    • Re: IB does not show Outlet/Action section in inspector
      • From: Kevin Cathey <email@hidden>
References: 
 >Re: IB does not show Outlet/Action section in inspector (From: Gregory Weston <email@hidden>)

  • Prev by Date: Re: drawing/masking one image with the alpha value from another
  • Next by Date: Re: Strategies for tracking a tricky (typing) slowdown/lag bug
  • Previous by thread: Re: IB does not show Outlet/Action section in inspector
  • Next by thread: Re: IB does not show Outlet/Action section in inspector
  • Index(es):
    • Date
    • Thread