Jump To:
Leopard Reference Library: Carbon
The Human Interface Toolbox is an object-oriented C API for implementing user interfaces, available in Mac OS X v10.2 and later. Controls, windows, and menus are subclassed from the HIObject base class or the HIView subclass; the HIObject object acts as the data store (instance), and Carbon event handlers are the methods. The standard toolbox managers (Window Manager, Control Manager, and so on) work seamlessly with this new model, while its object-oriented nature makes it much easier to create custom user interface elements.

Document Descriptions
On Off
Display

Sorted by
Title
Sort by
Resource Type
Sort by
Date
Adding an automated Window menu to your application (HTML)
QA1080: Explains how to add an automated Window menu to your Carbon application.
Technical Q&As 2001-10-30
AddNibToNav (HTML) (DMG) (ZIP)
Shows how to create a custom area, instantiated from a nib file, in a Navigation Services dialog.
Sample Code 2004-01-22
Appearance Manager Reference (HTML) (PDF)
Describes the C API for coordinating the look of the standard Mac OS human interface.
Reference 2007-01-23
Application Manager Reference (HTML) (PDF)
Describes the C API for performing various application-level tasks in a Carbon application. Formerly titled Dock Manager Reference.
Reference 2007-10-31
Are the root control, the root view, and the content view the same entity? (HTML) (日本語 HTML)
QA1214: Details the differences and similitudes between the root control, the root view, and the content view of windows.
Technical Q&As 2002-11-12
BasicDataBrowser (HTML) (DMG) (ZIP)
Shows how to create a basic, functional data browser.
Sample Code 2003-05-08
The Benefits of HIToolbox: the Evolving Widget Set (HTML)
Learn how to get started working with HIView control types.
Articles 2004-06-14
CalendarView (HTML) (DMG) (ZIP)
Shows how to subclass HIView using C, as well as drawing and hit testing.
Sample Code 2003-01-30
Can I have parameters of type typeHIRect instead of type typeQDRectangle in my kEventControlBoundsChanged message handler? (HTML) (日本語 HTML)
QA1246: Details the automatic coercions between QuickDraw and Quartz types provided by the Carbon Event Parameter accessors.
Technical Q&As 2003-04-03
Carbon Drawer problem in Mac OS X v10.4 and v10.4.1 (HTML)
QA1435: Workaround for a drawer problem present in Mac OS X v10.4 but fixed in v10.4.2
Technical Q&As 2005-06-21
Carbon Reference Update (HTML) (PDF)
Summarizes the symbols added to the Carbon framework.
Release Notes 2007-07-18
CarbonCocoa_PictureCursor (HTML) (DMG) (ZIP)
Demonstrates how to use NSCursor from a Carbon based application.
Sample Code 2007-01-12
CarbonCocoaCoreImageTab (HTML) (DMG) (ZIP)
Carbon-based application creates a Cocoa-based web window which used CoreImage filters to transition between tabbed WebViews
Sample Code 2006-07-25
CarbonMDEF (HTML) (DMG) (ZIP)
A Mac OS X-compatible, Appearance-savvy sample menu definition function (MDEF).
Sample Code 2003-01-30
CarbonTransparentWindow (HTML) (DMG) (ZIP)
Shows how to handle window transparency for compositing, non-compositing, and custom HIView-based Carbon windows.
Sample Code 2005-08-10
CGContext parameter missing in my kEventControlDraw event (HTML) (日本語 HTML)
QA1212: Explains in which case your kEventControlDraw handler wouldn't receive a CGContext parameter.
Technical Q&As 2002-11-12
Clickable Static Text Item (HTML)
QA1380: Explains how to make a static text item respond to clicks
Technical Q&As 2004-10-05
ClockView (HTML) (DMG) (ZIP)
An HIView sample that uses the HIFramework to implement a scalable analog clock.
Sample Code 2003-01-30
ColoredCheckBox (HTML) (DMG) (ZIP)
Demonstrates how to create a colored check box on a gray window backgrounds.
Sample Code 2003-01-30
ColorSwatchView (HTML) (DMG) (ZIP)
Implements a color well control as an HIView using HIFramework C++ Carbon Event wrapper classes.
Sample Code 2003-01-30
ComboBoxPrefs (HTML) (DMG) (ZIP)
Use CFPrefs to store URLs to images for use in a browser style combo box.
Sample Code 2005-10-04
Control Manager Reference (HTML) (PDF)
Describes the C API for creating and manipulating Carbon controls.
Reference 2007-03-26
ControlBackground (HTML) (DMG) (ZIP)
Shows how to affect the background color of a control when drawing it.
Sample Code 2003-01-30
Creating Carbon Menus (HTML) (PDF)
Describes how to create menus in Carbon applications.
Guides 2004-02-23
Custom_HIView_Tutorial (HTML) (DMG) (ZIP)
Tutorial presenting a step-by-step custom HIView development. All steps are documented and provided as standalone projects.
Sample Code 2005-06-01
CustomWindow (HTML) (DMG) (ZIP)
Demonstrates how to create a custom window in Mac OS X.
Sample Code 2003-01-30
CustomWindowWidget (HTML) (DMG) (ZIP)
Demonstrates two ways of adding a custom window widget to the window frame of a standard document window.
Sample Code 2003-01-30
The Data Browser GetDataBrowserUserState API (HTML) (日本語 HTML)
QA1270: Explains a problematic Data Browser API definition and how to work around it.
Technical Q&As 2003-07-22
Data Browser Programming Guide (HTML) (PDF)
Explains how to present data in lists similar to the list and column views in the Finder.
Guides 2007-08-07
Data Browser Reference (HTML) (PDF)
Describes the C API used to display data in list or column views similar to the Finder.
Reference 2008-04-08
Defining and Using the kTransformFocused IconTransformType (HTML)
QA1414: Documents a new IconTransformType, available in Panther and later, which draws a focus ring around an icon.
Technical Q&As 2005-03-29
Dialog Manager Helper Functions (HTML) (日本語 HTML)
TN1148: Discusses Dialog Manager calls available since System 7.0 that minimize work in managing dialogs.
Technical Notes 2000-08-14
Dialog Manager Reference (HTML) (PDF)
Describes the C interface for implementing alerts and dialog boxes.
Reference 2007-10-31
DialogsToHIViews (HTML) (DMG) (ZIP)
Shows how to convert from an old-style resource-based dialog to a modern nib-based window with HIViews.
Sample Code 2005-08-24
Do I have to call CreateRootControl after creating my window? (HTML) (日本語 HTML)
QA1215: Explains when and when not to call CreateRootControl after creating a window.
Technical Q&As 2002-11-12
DTSCarbonShell (HTML) (DMG) (ZIP)
Provides a modern Mac OS X Carbon Application Skeleton
Sample Code 2007-09-20
Enabling the application menu's "Preferences..." menu item on Mac OS X (HTML)
QA1079: Explains how to enable the application menu's "Preferences..." menu item on Mac OS X.
Technical Q&As 2001-10-30
Enabling the Navigation Services default behavior in its dialogs (HTML)
QA1384: Explains how to enable the default behavior of the Navigation Services dialogs.
Technical Q&As 2004-10-15
Filtering QuickTime media types in Navigation Services (HTML) (日本語 HTML)
QA1274: Describes how to filter QuickTime media types in a Navigation Services filter procedure.
Technical Q&As 2003-07-23
Finder Interface Reference (HTML) (PDF)
Describes several C data types used by the Finder to contain information about file system objects.
Reference 2006-10-31
Fixing the Layout Binding of the Tab control User Panes (HTML)
QA1161: Describes the Tab control hierarchy and layouts of its panes and provides a fix to a common problem.
Technical Q&As 2004-10-14
FloatingWindow (HTML) (DMG) (ZIP)
Demonstrates that floating windows are very easy to implement on Mac OS X using Nib files.
Sample Code 2003-10-24
GetDragHiliteColor (HTML) (DMG) (ZIP)
Shows how to obtain the color that Drag Manager uses to hilite regions when calling ShowDragHilite.
Sample Code 2003-01-30
GrabBag (HTML) (DMG) (ZIP)
Demonstrates variety of techniques and features of Carbon. DataBrowser , PBCatalogSearchAsync, Overlay windows, Tab controls, more...
Sample Code 2003-07-29
Guide to Creating Kiosks on Mac OS X (HTML) (日本語 HTML)
TN2062: Discusses techniques used in creating applications which require kiosk-like functionality on Mac OS X.
Technical Notes 2003-02-24
Handling Carbon Windows and Controls (HTML) (PDF)
A guidebook for implementing windows and controls in Carbon applications.
Guides 2005-07-07
HexEditorView (HTML) (DMG) (ZIP)
HIView subclass which implements a hex editor similar to those found in resource editors.
Sample Code 2003-01-30
HIArchive Programming Guide (HTML) (PDF)
Describes how to store data objects using HIArchive. Also includes information to make custom HIObjects archivable.
Guides 2005-08-11
HIArchive Reference (HTML) (PDF)
Describes the C API for storing and retrieving data in HIArchives.
Reference 2005-08-11
HICustomLeftRightSwitch (HTML) (DMG) (ZIP)
Illustrates how to create a custom left/right switch using the HIView functions introduced in Mac OS X 10.2.
Sample Code 2003-02-06
HICustomPushButton (HTML) (DMG) (ZIP)
Illustrates how to create a simple custom push button using the HIView functions introduced in Mac OS X 10.2.
Sample Code 2005-10-17
HideMenuBar (HTML) (DMG) (ZIP)
Shows how to hide the menu bar.
Sample Code 2003-01-30
HIDoubleSlider (HTML) (DMG) (ZIP)
Illustrates how to create a double slider using the Appearance and HIView functions introduced in Mac OS X 10.2.
Sample Code 2003-10-27
HIEmbedder (HTML) (DMG) (ZIP)
Shows how to write a custom embedding HIView which can scroll if set in an HIScrollView.
Sample Code 2003-11-13
HIFleetingControls (HTML) (DMG) (ZIP)
Implements fleeting controls such as seen in QuickTime Player full screen mode or iPhoto slideshow
Sample Code 2007-05-08
HIFramework (HTML) (DMG) (ZIP)
Contains C++ classes which are used by other HIToolbox sample code releases.
Sample Code 2003-02-06
HIGeometry Reference (HTML) (PDF)
Describes the C API that defines basic geometric objects for HIToolbox.
Reference 2007-06-11
High Level Toolbox Release Notes (10.4) (HTML)
Release Notes 2006-01-10
High Level Toolbox Release Notes (10.4.2) (HTML)
Release Notes 2006-01-10
High Level Toolbox Release Notes (10.4.3) (HTML)
Release Notes 2006-01-10
High Level Toolbox Release Notes (10.5) (HTML)
Describes new HIToolbox features and enhancements for Mac OS X v10.5.
Release Notes 2007-10-31
High Level Toolbox Release Notes (10.5.2) (HTML)
Describes HIToolbox enhancements for Mac OS X v10.5.2.
Release Notes 2008-03-11
HIObject Reference (HTML) (PDF)
Describes the C API for creating and manipulating human interface objects in Carbon applications.
Reference 2005-08-11
HIObjectRegisterSubclass returns paramErr (HTML) (日本語 HTML)
QA1213: Explains in which case HIObjectRegisterSubclass would return paramErr and gives a work around.
Technical Q&As 2002-11-12
HIObjectThreadController (HTML) (DMG) (ZIP)
Shows how threads can interact with the User Interface handled by the main thread of the application.
Sample Code 2005-08-10
HIScrollingTextBox (HTML) (DMG) (ZIP)
Offers replacement custom HIViews for the Scrolling TextBox control which does not work in compositing windows.
Sample Code 2003-11-06
HIShape Reference (HTML) (PDF)
Describes the Carbon API for manipulating HIShape objects.
Reference 2004-06-28
HISimpleList (HTML) (DMG) (ZIP)
Illustrates how to create a simple list using the HIView APIs introduced in Mac OS X 10.2.
Sample Code 2006-03-03
HITextShowcase (HTML) (DMG) (ZIP)
Illustrates some of the different text-related controls, non-controls, and HIViews that are available in Mac OS X 10.3.
Sample Code 2003-10-27
HITextViewDemo (HTML) (DMG) (ZIP)
Overview of basic HITextView functionality, including Tiger's new font & spelling panel support.
Sample Code 2005-06-01
HITextViewShowcase (HTML) (DMG) (ZIP)
Shows how to create a HITextView using Interface Builder and using programming functions only.
Sample Code 2003-10-30
HIToolbar Programming Guide (HTML) (PDF)
Explains how to create toolbars in Carbon applications.
Guides 2005-07-07
HIToolbar Reference (HTML) (PDF)
Describes the C API for creating and manipulating toolbars in Carbon applications.
Reference 2005-09-08
HIToolboxSOU-Delegates (HTML) (DMG) (ZIP)
Shows how to use the HIObject Delegate API.
Sample Code 2006-08-04
HIToolboxSOU-MenuItemViews (HTML) (DMG) (ZIP)
Shows how to use the Menu Item View API.
Sample Code 2006-08-04
HIView APIs vs. Control Manager APIs (HTML)
TN2074: Provides some clarification on the similar APIs and similar behaviors found in the HIView and Control Managers.
Technical Notes 2003-10-29
HIView Programming Guide (HTML) (PDF)
Describes view-based controls and how to implement them in Carbon applications.
Guides 2007-10-31
HIView Reference (HTML) (PDF)
Describes the C API for creating and manipulating view-based controls and menus in Carbon applications.
Reference 2007-04-13
HIView-NSView (HTML) (DMG) (ZIP)
Demonstrates how to embed an NSView within an HIView in a Carbon window.
Sample Code 2007-05-29
HIViewTest (HTML) (DMG) (ZIP)
An HIView with rudimentary drawing and hit testing.
Sample Code 2003-01-30
How can I handle smooth mouse wheel scrolling? (HTML)
QA1453: Details an undocumented Carbon Event which will be added to the public headers in a later DevTools release.
Technical Q&As 2005-11-29
How can I set the default location with the modern Navigation APIs NavCreatexxx? (HTML) (日本語 HTML)
QA1151: Explains how to set the default location with a NavCustomControl call using the kNavCtlSetLocation message in the Event Proc.
Technical Q&As 2002-07-01
How PBDTGetAPPL Chooses Which Copy of an App to Launch (HTML) (日本語 HTML)
Deprecated - TB19: Explains how PBDTGetAppl() chooses which application copy to launch, and how to deal with the trash.
Technical Q&As 1996-05-14
How to use the ATSUI Low Level APIs to get glyph outlines (HTML) (日本語 HTML)
TN2033: Covers the ATSUI low-level APIs.
Technical Notes 2001-11-26
icon cache demo (HTML) (DMG) (ZIP)
Demonstrates the use of an icon cache to limit the search for icon resource to one resource file.
Sample Code 2003-01-30
Icon Play (HTML) (DMG) (ZIP)
Demonstrates the use of icon utilities and popup control cdef in a program using modal dialogs.
Sample Code 2003-01-30
Icon Services and Utilities Reference (HTML) (PDF)
Describes the C API for manipulating and drawing icons in Carbon applications.
Reference 2007-04-06
IconUtilCheck (HTML) (DMG) (ZIP)
Shows how to determine whether the Icon Utilities are available.
Sample Code 2003-01-30
ImageBrowserView (HTML) (DMG) (ZIP)
Implementing a simple HIView subclass
Sample Code 2005-06-01
ImageMapView (HTML) (DMG) (ZIP)
Demonstrates how to add Accessibility to a complex custom HIView and the related parts of an application.
Sample Code 2005-10-17
Installing input methods on Mac OS X (HTML)
QA1054: Describes how to install and use input methods on Mac OS X.
Technical Q&As 2001-09-14
The intermittent behavior of SetDialogItemText (HTML)
Deprecated - QA1082: Explains why SetDialogItemText may seem to not work correctly if you have embedding turned on.
Technical Q&As 2001-10-30
List Manager Reference (HTML) (PDF)
Deprecated - Describes the legacy C API for managing and displaying elements in a scrollable list. Replaced by the Data Browser.
Reference 2007-12-11
LittleArrowsShowcase (HTML) (DMG) (ZIP)
How to increment and decrement the LittleArrows value when the user clicks on the up and down buttons.
Sample Code 2006-11-09
Losing the character code when using the control key (HTML)
QA1446: Explains why the control key transforms the character code instead of simply setting the appropriate modifier bit.
Technical Q&As 2006-07-17
Mac OS X 10.3 Navigation Services Changes (HTML) (日本語 HTML)
TN2105: Explains Navigation Services changes in Mac OS X 10.3 Panther
Technical Notes 2004-01-30
Managing custom drawing code in a compositing world (HTML)
QA1162: Explains why any custom drawing code must be handled by the kEventControlDraw handler of a custom HIView
Technical Q&As 2004-10-14
Menu Manager Reference (HTML) (PDF)
Describes the C API for creating and managing an application's menus.
Reference 2006-09-15
MenuViews (HTML) (DMG) (ZIP)
Demonstrates a variety of interesting uses of HIView-based menus in Mac OS X 10.3.
Sample Code 2003-10-24
MLTE_CustomScrolling (HTML) (DMG) (ZIP)
Shows how to implement MLTE's custom scrolling functionality
Sample Code 2004-10-15