Search code examples
cocoaqtmacosmacos-carbon

Qt or wxWidgets on Cocoa?


I was told that the newest Qt is Cocoa based, and as so, it's 64 bit. And Cocoa is Object-C based, whereas Qt is C++ based.

  • How is that possible? I mean, how C++ based library can turn into Objective-C related one? Is this just using Objective-C++?
  • Can any C++ library be Cocoa based using Objective-C++?

Solution

  • Objective-C++ lets you combine C++ and Objective-C in the same source file. So you can do interesting things here. For example, I've created C++ classes that call Cocoa things like NSNotification before.

    So I suspect you'd just write in C++, calling C++ objects... which are implemented as C++ wrappers of Objective-C methods.

    wxWidgets has a similar thing going on, wxCocoa, but last I heard that was the Mac platform of the future, meaning that they are still building it.