Chapter 4. Interface Builder

In This Chapter

  • Finding your way around Interface Builder

  • Adding controls to an interface

  • Editing attributes of a control

  • Editing and creating new menus

  • Wiring an interface

  • Implementing code to use an interface

The second most important component of Cocoa development (Xcode is the first; see Chapter 3) is the eponymous Interface Builder application, which you use to build interfaces for your Cocoa projects. Interface Builder gives you the ability to construct beautiful interfaces for your software with drag-and-drop ease — without a lick of code. More importantly, the interfaces you create in Interface Builder follow Apple's stringent Human Interface Guidelines, so you have a good chance of producing applications that Mac users (they can be a finicky bunch) like to look at and ultimately use.

In this chapter, you take a tour of Interface Builder, examining its functionality as you go. To help you acclimate to Interface Builder, you improve the calculator application that you created in Chapter 3. By the end of this chapter, your calculator will have a new menu, additional interface elements, and added functionality.

Note

You can find the project files for this chapter on the For Dummies Web site at www.dummies.com/go/cocoafd.

A Tour of Interface Builder

To begin working with Interface Builder, make a copy of the finished Chapter 3 project folder. Always make sure that your Cocoa projects and associated files reside on write-enabled media, which is most likely your ...

Get Cocoa® Programming for Mac OS® X For Dummies® now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.