Developing for the Mac?


Recommended Posts

Great, thanks!

What about C++?  Is that used in OS X?

Mark

585803534[/snapback]

C++ can be used, but it's not nearly as native as Objective-C is to OS X. If I remember correctly, C++ will produce Carbon apps whereas Objective-C will produce Cocoa apps, even thought both can use Cocoa (e.g. Finder).

So it doesn't really matter if you use Cocoa or Carbon?  I read a while ago that Cocoa apps were slow and unstable.  I haven't seen anything like that with cocoa apps I use but just a question.

Thanks

Mark

585807595[/snapback]

Cocoa apps are the native type for OS X, so I don't understand why someone would say that (perhaps it was an old article you read?). Carbon apps can run on either OS 9 or OS X.

To say that Carbon isn't "OS X native" is a bit of a misleading unless these people are trying to say that programs like Finder are not "native". In some places Cocoa is falling back on Carbon calls (ie: Menus) so if Carbon application's aren't native, neither are ones written using Cocoa. They are different but one is not inferior to the other in and of itself. Much like operating systems the value of each is best determined by what you're trying to do. If you need a very dynamic GUI application fast then you'll probably want Cocoa, if you're concerned with speed and backward compatability with OS 9 users then you'll want Carbon. There's an article on O'reilly's Mac Developer Center about this so I won't bother making those same points. Carbon is not dead, it's not 'bad', and it's not out-dated: it's just got different strengths than Cocoa does.

There are four major languages used for OS X development these days:

  • C++
  • Objective C
  • Java
  • Objective C++

Python is getting a lot of attention lately and Apple finally poured a little love onto AppleScript Studio in 10.4 so you would do well to study either of those. The transition to OS X programming with Cocoa+Objective C will be easier if you already understand OOP concepts and SmallTalk. In 10.4 you would do well to study up on ERD diagrams: it can save you a lot of work. Most of the standard UNIX programming concepts work pretty well in OS X, if you have plans to write 64-bit applications then you should get comfortable with C/C++ programming and Pipes: there's really no other way to do it because Cocoa isn't 64-bit clean. If you know VB6 already then you can get a jump by ordering a copy of RealBASIC. I'm not sure why everyone seems to expect you to develop using Xcode now: powerplant & code warrior used to be perfectly fine

The three books I would most recommend are Sams? Cocoa Programming O'Reilly?s Learning Cocoa with Objective C and New Riders? Mac OS X programming.

The Sams book is an in-depth reference reference that covers not only how to use the IDE and APIs but also explains why Mac OS X is different from on other platoforms; for example, Cocoa force MVC patterns down your throat until you crap controller objects. I bought my copy when Project Builder was still the norm so (unless they've updated) be prepared to spend a few minutes mapping the old interface to the new while you work through examples.

The O'Reilly book is a little light on details. It's got a very accessible introduction to Core Foundation and Objective C and it introduces the debugging tools very early on but I found it to be more of a high-level overview of Mac OS X development rather than an in-depth guide to Cocoa.

I found ADC nearly useless as a 'getting started' resource. Once you're comfortable with how things work it's a respectable API reference and you can generally get the basics of unfamiliar/new APIs pretty quickly. That said, there are enough holes in the documentation that I don't think it's worth the $500+/year unless you take them up on offers like WWDC tickets or use of the testing facilities: the student membership has served me well enough.

To be honest I haven't finished the Carbon Book (Mac OS X Programming) but the parts I have read made it worth the $50 or so that I paid for it.

EDIT: I said "core foundation" when I meant foundation. Doh!

Edited by the evn show
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Posts

    • Lol I had one of these turn faulty in Jan, guess it wasn't just bad luck lol
    • I'm team Rossmann all the way. I have the exact same NVME, altough not in an array like him.
    • It had gone weeks ago. Although thinking about it I'm on the beta.
    • They thought value of their goods would forever only drop like it used to and didn't account for sudden increase in price because of all the Ai hype. Tough luck Samsung, don't try to weasel this one out. Also American customer protection laws are a**. In Europe, you need to be compensated for a functioning product of same or better characteristics (not same price point as when it was originally bought!) if it can't be repaired and when you receive a replacement product your warranty starts from scratch because you received a different item than you previously had and old warranty thus cannot apply to it anymore. If your actual item was successfully repaired, warranty gets extended for the period the item was in service. If item is repaired to a significant extent, warranty also starts over from scratch because major part of it was replaced. Americans need to fight to get this kind of consumer protections because they are constantly getting screwed over.
    • Microsoft releases new Windows 11 Media Creation Tool with the latest updates by Taras Buria Patch Tuesday updates arrive every month, bringing users new features and security updates. To make sure customers have access to the most recent images, Microsoft also releases updates to the Media Creation Tool app, its official utility for Windows 11 installation. Today, the company pushed new ISOs to Media Creation Tool, allowing you to create images with the June 2026 Patch Tuesday updates. With the latest update, the Media Creation Tool now downloads KB5094126. It is Windows 11 version 25H2, build 26200.8655, which is also available via Windows Update. Note that the app itself remains on the previous version, which you can check in Properties > Details. The only change is that it now downloads a more recent Windows 11 build, so the only way to check is to download an ISO. The June 2026 Patch Tuesday update is a special release for Windows 11, as it brings a new performance profile to make the operating system more responsive and snappier when rendering various user interface surfaces, including the Start menu, quick settings, and more. It does so by spiking processor speeds for a brief moment, resulting in higher loads for a second or two. The so-called “Low latency profile” is rolling out gradually, but you can force-enable it with the ViVeTool app. Other changes include webcam improvements, Task Manager updates, shared audio support, and more. You can download the Media Creation Tool app from the official Microsoft website using this link. Besides MCT, Microsoft lets you download Windows 11 ISO as a file directly from the official Windows 11 website. However, you will need a third-party app to write it to your USB drive. Check out this guide if you want to know how to do that.
  • Recent Achievements

    • Week One Done
      davidbazooked earned a badge
      Week One Done
    • One Month Later
      Jamswaz earned a badge
      One Month Later
    • Week One Done
      Jamswaz earned a badge
      Week One Done
    • Rookie
      Marzoid went up a rank
      Rookie
    • Community Regular
      coch went up a rank
      Community Regular
  • Popular Contributors

    1. 1
      +primortal
      509
    2. 2
      PsYcHoKiLLa
      184
    3. 3
      +Edouard
      158
    4. 4
      Steven P.
      83
    5. 5
      ATLien_0
      75
  • Tell a friend

    Love Neowin? Tell a friend!