O'Reilly logo

Mac OS® X Advanced Development Techniques by Joe Zobkiw

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

16. Snippets

“Just one line of code; the hard part is figuring out which one.”

—Mike Trent

This chapter is designed to offer a plethora of code snippets and tips in various forms to help you get the most out of your Mac OS X development efforts. You will find various languages represented here. Many of these snippets are demonstrated in the Project Builder project that goes with this chapter. Enjoy!

Calling Carbon from Cocoa

It is very easy to call traditional Carbon functionality from within your Cocoa application. Simply include the framework Carbon.framework in your project, #import <Carbon/Carbon.h> in the source file you will be calling from, and make the call. Cocoa and Carbon live peacefully together with nary a bad thought for one another. ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required