Jump To:
Each Sample Code project is buildable and executable source example of how to accomplish a task for a specific Apple technology. They show the correct sequence of calls and parameter data types to provide a generalized method for API use that developers can modify for their specific needs.

Document Descriptions
On Off
Display

Sort by
Title
Sort by
Topic
Sorted by
Date
ColorSwatchView (HTML) (DMG) (ZIP)
Implements a color well control as an HIView using HIFramework C++ Carbon Event wrapper classes.
Carbon 2003-01-30
ControlBackground (HTML) (DMG) (ZIP)
Shows how to affect the background color of a control when drawing it.
Carbon 2003-01-30
CustomWindow (HTML) (DMG) (ZIP)
Demonstrates how to create a custom window in Mac OS X.
Carbon 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.
Carbon 2003-01-30
Fragment Tool (HTML) (DMG) (ZIP)
Demonstrates manipulation of code fragments; combining and separating; viewing and editing information associated with each.
Carbon 2003-01-30
GetDragHiliteColor (HTML) (DMG) (ZIP)
Shows how to obtain the color that Drag Manager uses to hilite regions when calling ShowDragHilite.
Carbon 2003-01-30
HandyScrollingSample (HTML) (DMG) (ZIP)
Shows some ways of implementing scrolling.
Carbon 2003-01-30
HexEditorView (HTML) (DMG) (ZIP)
HIView subclass which implements a hex editor similar to those found in resource editors.
Carbon 2003-01-30
HideMenuBar (HTML) (DMG) (ZIP)
Shows how to hide the menu bar.
Carbon 2003-01-30
HIViewTest (HTML) (DMG) (ZIP)
An HIView with rudimentary drawing and hit testing.
Carbon 2003-01-30
HTMLSample (HTML) (DMG) (ZIP)
Deprecated - Illustrates one way to use the HTMLRenderingLib Library.
Carbon 2003-01-30
HTMLUserPane (HTML) (DMG) (ZIP)
Deprecated - Shows how to display a HTMLRenderingLib object inside of a user pane control.
Carbon 2003-01-30
icon cache demo (HTML) (DMG) (ZIP)
Demonstrates the use of an icon cache to limit the search for icon resource to one resource file.
Carbon, Graphics & Imaging, Performance 2003-01-30
Icon Play (HTML) (DMG) (ZIP)
Demonstrates the use of icon utilities and popup control cdef in a program using modal dialogs.
Carbon 2003-01-30
IconUtilCheck (HTML) (DMG) (ZIP)
Shows how to determine whether the Icon Utilities are available.
Carbon 2003-01-30
ictbSample (HTML) (DMG) (ZIP)
Deprecated - Shows an example of ictb resource.
Carbon 2003-01-30
Image Difference (HTML) (DMG) (ZIP)
Demonstrates a way to use Quartz's compositing capability to find the difference between two images.
Cocoa, Graphics & Imaging 2003-01-30
kcapApp (HTML) (DMG) (ZIP)
Demonstrates drawing the key caps, given a set of modifiers and KCHR and KCAP resource IDs.
Carbon 2003-01-30
KeyMapTest (HTML) (DMG) (ZIP)
Uses Pascal to display a KeyMap representation whenever keys are pressed.
Carbon 2003-01-30
Live Scroll (HTML) (DMG) (ZIP)
Deprecated - Demonstrates how to implementing live scrolling during the tracking of scroll bar thumbs.
Carbon 2003-01-30
LocalServer (HTML) (DMG) (ZIP)
Deprecated - Sample demonstrates how a Classic process can communicate with a Mac OS X process using IP networking protocols.
Carbon, Core Foundation, Internet & Web, Networking, Porting 2003-01-30
NoSound (HTML) (DMG) (ZIP)
Illustrates how to install a procedure to be executed when the user restarts or shuts down.
Carbon 2003-01-30
Password (HTML) (DMG) (ZIP)
Deprecated - Illustrates three different ways to implement password fields in dialogs.
Carbon 2003-01-30
PopUpMenuWithCurFont (HTML) (DMG) (ZIP)
Deprecated - Demonstrates what must be done to control the font used by MDEF 0 during PopUpMenuSelect.
Carbon 2003-01-30
ReadLocation (HTML) (DMG) (ZIP)
Retrieves the Map control panel settings for longitude and latitude and the time offset from GMT.
Carbon 2003-01-30
ReKeyTrans (HTML) (DMG) (ZIP)
Shows how to patch KeyTrans to ignore dead-key processing so you type fancy accented characters.
Carbon 2003-01-30
ROMResourceDump (HTML) (DMG) (ZIP)
Deprecated - Illustrates how to copy all resources in the Macintosh's ROM into a file.
Carbon 2003-01-30
Scrap Parsing (HTML) (DMG) (ZIP)
Deprecated - Shows how to parse the in-memory scrap.
Carbon 2003-01-30
SetIndString (HTML) (DMG) (ZIP)
Implements SetIndString(), which sets a particular STR# string to the passed in string. Similar to GetIndString()
Carbon 2003-01-30
SetWindBackColor (HTML) (DMG) (ZIP)
Demonstrates how to programmatically set the background color of a window without flicker without the Appearance Manager.
Carbon 2003-01-30
SICN LDEF (HTML) (DMG) (ZIP)
Implements an LDEF that displays small icons to the left of text in a list.
Carbon 2003-01-30
SimpleList (HTML) (DMG) (ZIP)
A simple illustration of a ListBox Control implementation and its pitfall
Carbon 2003-01-30
Splasher (HTML) (DMG) (ZIP)
Closes a modal window, such as a splash screen, with a mouse click or key press.
Carbon 2003-01-30
SplitView (HTML) (DMG) (ZIP)
An HIView sample that uses the HIFramework and implements a scalable split view.
Carbon 2003-01-30
stdFilterHacking (HTML) (DMG) (ZIP)
Demonstrates problems and workarounds for/with the Standard Dialog Filter.
Carbon 2003-01-30
TickerView (HTML) (DMG) (ZIP)
HIView subclass which implements a scrolling, live stock ticker.
Carbon 2003-01-30
URLTextView (HTML) (DMG) (ZIP)
An HIView subclass which uses LaunchServices to open the URL attached to the view.
Carbon 2003-01-30
Vertest (HTML) (DMG) (ZIP)
Demonstrates how to access the information from the Vers Resource. Developed for Tech Note #189.
Carbon 2003-01-30
qtdataref (HTML) (DMG) (ZIP)
Shows how to work with data references and data handlers.
QuickTime 2003-01-24
qtdataref.win (HTML) (DMG) (ZIP)
Shows how to work with data references and data handlers.
QuickTime 2003-01-24
PDFView (HTML) (DMG) (ZIP)
Shows how to display or print a multi-page PDF document and scroll an NSscrollview's contents by dragging.
Cocoa 2003-01-23
AddFrameToMovie (HTML) (DMG) (ZIP)
Shows how to add an additional frame to the end of an existing movie.
QuickTime 2003-01-14
AddressBookCarbon (HTML) (DMG) (ZIP)
Demonstrates some basic manipulations of the Mac OS X 10.2.x (and beyond) Address Book API.
Apple Applications, Carbon 2003-01-14
AddressBookCocoa (HTML) (DMG) (ZIP)
Demonstrates some basic manipulations of the Mac OS X 10.2.x (and beyond) Address Book API.
Apple Applications, Carbon, Cocoa 2003-01-14
AddTextMovie.win (HTML) (DMG) (ZIP)
Shows how to Add a text track to a Movie.
Java, QuickTime 2003-01-14
addvractions (HTML) (DMG) (ZIP)
Illustrates how to add wired actions to a QuickTime VR movie.
QuickTime 2003-01-14
addvractions.win (HTML) (DMG) (ZIP)
Illustrates how to add wired actions to a QuickTime VR movie.
QuickTime 2003-01-14
AESendandReceive (HTML) (DMG) (ZIP)
Deprecated - Sending and receiving Apple Events with JDK 1.3.1 on Mac OS X.
Java 2003-01-14
aglClipBufferRect (HTML) (DMG) (ZIP)
Shows the use of clip regions and buffer rects in AGL.
Carbon, Games, Graphics & Imaging 2003-01-14
AIFFWriter (HTML) (DMG) (ZIP)
Deprecated - A Sound Manager sound output device component.
QuickTime 2003-01-14
aiffwriter.win (HTML) (DMG) (ZIP)
Deprecated - A Sound Manager sound output device component.
QuickTime 2003-01-14
AlwaysPreview (HTML) (DMG) (ZIP)
Demonstrates how to force the preview enabled mode by install a modal dialog filter proc in CustomGetFilePreview.
QuickTime 2003-01-14
AnimatedSlider (HTML) (DMG) (ZIP)
Demonstrates the use of an NSTimer to animate a control in Cocoa.
Cocoa 2003-01-14
ATSUICurveAccessDemo (HTML) (DMG) (ZIP)
Demonstrates low-level ATSUI APIs which allow access to raw glyph curve data.
Carbon, Internationalization 2003-01-14
ATSUIDirectAccessDemo (HTML) (DMG) (ZIP)
Demonstrates some basic manipulations of the ATSUI DirectAccess api.
Carbon, Internationalization, Text & Fonts 2003-01-14
audioburntest (HTML) (DMG) (ZIP)
Uses the DRTrackCallbackProc and track properties to create a RedBook audio CD from AIFF files.
Carbon 2003-01-14
audiocodec (HTML) (DMG) (ZIP)
A Sound Manager compressor and decompressor example supporting the uLaw format.
QuickTime 2003-01-14
audiocodec.win (HTML) (DMG) (ZIP)
An example codec, a compressor and decompressor supporting the uLaw format.
QuickTime 2003-01-14
audioconverter.win (HTML) (DMG) (ZIP)
SoundConverter routines to convert AIFF and AIFC files into AIFF/AIFC or QuickTime. Parse AIFF/AIFC files.
QuickTime 2003-01-14
BasicInputMethod (HTML) (DMG) (ZIP)
An input method implemented as a text service component for Mac OS X.
Carbon, Text & Fonts, User Experience 2003-01-14
BlitNoVBL (HTML) (DMG) (ZIP)
Shows how to draw directly to the screen without syncing to the VBL of the monitor.
Graphics & Imaging, Performance 2003-01-14
BlitVBL (HTML) (DMG) (ZIP)
Shows how to have Mac OS X try its best to sync to the VBL for you.
Games, Graphics & Imaging, Hardware & Drivers, Performance 2003-01-14
bulkerase (HTML) (DMG) (ZIP)
Demonstrates how to erase media using the DiscRecording framework.
Carbon 2003-01-14
BurntTextSampleCode (HTML) (DMG) (ZIP)
Converts text tracks of a movie to new text tracks with bit map representations of the text.
QuickTime 2003-01-14
CapabilitiesSample (HTML) (DMG) (ZIP)
Shows how to detect Image Capture device capabilities and send messages to devices with ICAObjectSendMessage.
Apple Applications 2003-01-14
CarbonQTGraphicImport (HTML) (DMG) (ZIP)
Illustrates how to use the QuickTime GraphicImporter components.
QuickTime 2003-01-14
CarbonQuartzDrawingWPrinting (HTML) (DMG) (ZIP)
Deprecated - Demonstrates mixing QuickDraw and Quartz 2D drawing both on screen and during printing.
Carbon, Graphics & Imaging, Printing 2003-01-14
CD-ROM Detection (HTML) (DMG) (ZIP)
Shows how to determine whether a drive is a CD-ROM drive.
Hardware & Drivers 2003-01-14
CFPreferences (HTML) (DMG) (ZIP)
Shows how to use the CFPreferences APIs to access user preferences.
Carbon, Core Foundation 2003-01-14
CFPrefsDumper (HTML) (DMG) (ZIP)
Shows how to use the CFPreferences APIs to access information about the current user preferences.
Carbon, Core Foundation 2003-01-14
CGDrawPicture (HTML) (DMG) (ZIP)
Deprecated - Shows how to use the QDPictDrawToCGContext API.
Cocoa, Graphics & Imaging 2003-01-14
CGGamma (HTML) (DMG) (ZIP)
Shows how to use CGDirectDisplay calls to manipulate display gamma tables.
Games, Graphics & Imaging 2003-01-14
ChromaKeyMovie (HTML) (DMG) (ZIP)
Demonstrates alternative approaches to removing a color from a QuickTime movie.
QuickTime 2003-01-14
Cocoa - SGDataProc (HTML) (DMG) (ZIP)
Uses a Sequence Grabber data function and an NSQuickDrawView to simulate a preview operation for captured video.
Cocoa, QuickTime 2003-01-14
CocoaCreateMovie (HTML) (DMG) (ZIP)
Demonstrates how to create a QuickTime movie from a set of Cocoa JPEG NSImage objects.
QuickTime 2003-01-14
CocoaDragAndDrop (HTML) (DMG) (ZIP)
Implement Drag-and-Drop functionality in Cocoa (uses images; can be extended to support other data types).
Cocoa 2003-01-14
CocoaVideoFrameToGWorld (HTML) (DMG) (ZIP)
Demonstrates how to draw each frame of a QuickTime movie into a Cocoa NSQuickDrawView.
Cocoa, QuickTime 2003-01-14
CocoaVideoFrameToNSImage (HTML) (DMG) (ZIP)
Demonstrates how to create an NSImage for each frame of a QuickTime movie.
Cocoa, QuickTime 2003-01-14
Color Sampler (HTML) (DMG) (ZIP)
Demonstrates one way to sample the color at a given point in an NSView.
Cocoa 2003-01-14
ColorBars (HTML) (DMG) (ZIP)
Shows how to enumerate, select, capture, manipulate, draw to, and release displays using the CGDirectDisplay API.
Carbon, Cocoa, Graphics & Imaging 2003-01-14
ColorSyncDevices (HTML) (DMG) (ZIP)
Demonstrates how to use the new ColorSync Device Support APIs introduced with Mac OS X.
Carbon, Graphics & Imaging 2003-01-14
ColorSyncDevices-Cocoa (HTML) (DMG) (ZIP)
Demonstrates how to use the new ColorSync Device Manager routines in the Cocoa environment.
Carbon, Cocoa 2003-01-14
CompressMovies (HTML) (DMG) (ZIP)
Shows how to use QuickTime movie compression in an application.
QuickTime 2003-01-14
ConvertMovieSndTrack (HTML) (DMG) (ZIP)
Demonstrates using the Sound Converter to transcode a Sound Track from one audio encoding format to another.
QuickTime 2003-01-14
ConvertToMovieJr (HTML) (DMG) (ZIP)
Shows how to recompress QuickTime movies using the Image Compression Manager routines.
QuickTime 2003-01-14
CreateMovie (HTML) (DMG) (ZIP)
Demonstrates how to create a QuickTime Movie with both a video and audio track.
QuickTime 2003-01-14
CreateMovieJava (HTML) (DMG) (ZIP)
Deprecated - Creates a Movie from Java drawing and a sound file.
QuickTime 2003-01-14
Cropped Image (HTML) (DMG) (ZIP)
Demonstrates how to extract a sub-image from another image, and some ways of indicating a selection.
Cocoa 2003-01-14
CTMClip (HTML) (DMG) (ZIP)
Deprecated - Shows how to manipulate the Quartz 2D Current Transform Matrix (CTM) for image drawing with clipping.
Carbon, Cocoa, Graphics & Imaging 2003-01-14
CTMDemo (HTML) (DMG) (ZIP)
Deprecated - Shows how to manipulate the Quartz 2D Current Transform Matrix (CTM) for image drawing without clipping.
Carbon, Cocoa, Graphics & Imaging 2003-01-14
databurntest (HTML) (DMG) (ZIP)
Demonstrates how to create a DRFolderRef and burn it to disc.
Carbon 2003-01-14
DecompressionAndScaling (HTML) (DMG) (ZIP)
Shows how to convert a version 2 PICT to a compressed QuickTime data buffer.
QuickTime 2003-01-14
DeskPictAppDockMenu (HTML) (DMG) (ZIP)
How to add a dynamic Dock menu to your Cocoa application
Cocoa, Scripting & Automation 2003-01-14
DigitizerShell (HTML) (DMG) (ZIP)
Simple sequence grabber and vdig test bed for testing vdig and digitizer functionality.
QuickTime 2003-01-14
DragAndDrop Shell (HTML) (DMG) (ZIP)
A Drag and Drop shell for producing QuickTime drag and drop tools.
Carbon, QuickTime 2003-01-14
DrawTextCodec (HTML) (DMG) (ZIP)
This is a QuickTime codec for compressing black and white pictures into the glyphs of a font.
QuickTime 2003-01-14
EnhancedDataBurn (HTML) (DMG) (ZIP)
Objective-C sample which shows how to burn a data disc containing a complete virtual filesystem.
Cocoa 2003-01-14
Eraser (HTML) (DMG) (ZIP)
Uses the DiscRecordingUI framework to present the standard erase, selection and progress dialogs.
Cocoa 2003-01-14
ExampleCodec (HTML) (DMG) (ZIP)
An example of am image compression codec that handles both compression and decompression of images.
QuickTime 2003-01-14
ExampleVideoPanel (HTML) (DMG) (ZIP)
An example Sequence Grabber Video Panel Component.
QuickTime 2003-01-14