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

    • Wow, imagine you dump hundreds of hours into completing things and unlocking stuff and you lose it all. Back in the day when cheats were built into games, you could at least unlock things again that way without spending hundreds of hours again. But those days are long gone for some reason as no one builds cheats into games anymore. So it's even more painful that studio that's on its 6th installment **** it up so badly.
    • Spotify finally removes the disco ball app icon in the latest update by Ivan Jenic Image: Spotify Spotify has just released an update that removes its now infamous disco ball icon. The update reverts the app icon to the familiar flat green logo after weeks of mixed reactions online. The icon arrived on May 13 as part of the company's 20th anniversary celebration and was always intended to be temporary, though Spotify only confirmed that after the backlash started. The disco ball took the internet by storm, as the reception was split. A vocal group of users called it ugly and disorienting, with some iOS users noting that the 3D glowing effect made the app look like it was stuck mid-update. On the other end, the icon picked up a following of its own. Its retro, three-dimensional look immediately stood out against the flat, minimalist aesthetic that has dominated app design for years. It even started a small movement, spawning what people started calling "discomorphism," a mashup of disco and skeuomorphism. Other brands started posting disco ball versions of their own logos, probably in an effort to ride the wave of memes that flooded the internet during late May. Spotify has had a turbulent relationship with its user base lately. Besides the disco ball icon, which certainly wasn't appreciated by everyone, the company has also received backlash for its willingness to include AI-generated music on its platform. On May 17, Spotify promised the old icon would return “in a few weeks.” And now it looks like that time has finally arrived. So, whether you liked the disco ball or it made you uncomfortable, it’s now gone for good. The next time you update the Spotify app on your phone, the old, flat-design icon will return.
    • Playground Games confirms Forza Horizon 6 save wipe bug by Taras Buria Forza Horizon 6 was launched last month to critical acclaim (check out our review here), and it became a smash hit in an instant. Now, weeks into the launch, with die-hard fans clocking hundreds of hours, Forza Horizon 6 is facing a serious issue: save wipes. After multiple complaints on Reddit and social media, the studio issued a statement. The problem with missing saves came shortly after Playground Games promised the initial batch of gameplay tweaks and improvements. Unfortunately, there seems to be no temporary fixes for those affected by unexpected save wipes. However, the studio published a new support document with a few important steps users should try. First, affected gamers should open a support ticket immediately (go here to file one) so that the support team can try recovering the lost progress by reverting to an earlier save. Playground Games says this should be done the same day the issue occurs. Meanwhile, gamers are urged not to start new play sessions or create new saves. The studio also published a few things gamers should try to avoid to prevent potential progress loss: Ensure your Gaming Services app on PC or XBOX Series X|S console is fully up to date. On XBOX Series X|S consoles, disable Quick Resume for Forza Horizon 6: To disable Forza Horizon 6 from using Quick Resume, highlight the game box art anywhere in the console experience (Home, My Games & Apps, Pins, etc) and then press the Menu button, then go to Manage game and add-ons > Quick Resume settings > Disable Quick Resume. Ensure you are online when ‘quitting’ the game. Give your saved time to sync to the cloud before powering off or switching devices. Do not force quit the game during save screens. Do not power off the device during gameplay. Always "Quit" (console) or "Exit to desktop" (PC) once you've finished your play session, ensuring the save icon is not visible when you’re closing the game. Before turning off your console, shutting down your PC, or force-closing the Steam app, give your devices or clients at least a few minutes to ensure your latest progress has been synchronized with the cloud. This will reduce the risk of progress reversions as you switch between different platforms. XBOX Series X|S consoles, Steam, and the XBOX app on PC all include game save indicators that confirm your progress has been synced. You can read more about the bug in the official support document here. Forza Horizon 6 is currently available on PC (Steam and the Microsoft Store), Xbox Series X|S, and Game Pass. The game is also coming to PlayStation 5 later this year.
  • Recent Achievements

    • One Year In
      slackerzz earned a badge
      One Year In
    • One Year In
      highriskpaym earned a badge
      One Year In
    • One Month Later
      highriskpaym earned a badge
      One Month Later
    • Week One Done
      highriskpaym earned a badge
      Week One Done
    • Week One Done
      FBSPL earned a badge
      Week One Done
  • Popular Contributors

    1. 1
      +primortal
      519
    2. 2
      PsYcHoKiLLa
      198
    3. 3
      +Edouard
      158
    4. 4
      Steven P.
      84
    5. 5
      ATLien_0
      75
  • Tell a friend

    Love Neowin? Tell a friend!