The genesis of Carbon is from the original Macintosh API. Much of this Classic Macintosh API was written in Pascal. You will still occasionally see functions, particularly callbacks that use the Pascal keyword (on the original 68K CPUs, this ensured a proper ordering of parameters on the stack - on PowerPC or x86 it has no effect). There are still some places that use Pascal strings. ie. strings of characters preceded by a length byte and not null terminated. Apple provided a C interface for much of the toolbox long ago and most Classic programs are written in C or C++.
When Steve Jobs returned to Apple he brought much of the NextStep API with him to Apple. This API was written in Objective-C and based on the UNIX operating system.
Apple split their platform into two flavors; Cocoa which is most like NextStep and Carbon which is most like Classic Macintosh.
I think there are two flavors of Carbon.
First, is Graphite Carbon or Porting Carbon; which is the minimal amount of changes you need to make to an old Classic application to get it to run native on OS X. It should still run on OS 9 and maybe OS 8. Graphite is often used as a good lubricant. This will help grease up those old apps so they slide nicely into OS X.
The second is Diamond Carbon or Modern Carbon. Diamond Carbon involves a fresh start at much of the API. It is the correct way to do things for the future. It is closer to Cocoa in design and features. Diamonds are bright and shiny. Like you get when you use the new Aqua interface for your Carbon apps.
As you dig through the documentation and example you will see evidence of both Graphite Carbon and Diamond Carbon. There are almost always (at least) two ways to do everything. Again, this makes it confusing to learn what to do.
| Graphite | Diamond |
| FSSpec | FSRef |
| Control Manager | Human Interface Toolbox |
| QuickDraw | Quartz |
| Scrap Manager | Pasteboard |
| ControlRef | HIViewRef |
| Str255 | CFString |