Important: The information in this document is obsolete and should not be used for new development.
MyGetIconData
Color picker-defined subroutine that handles akGetIconData
request.If you create a color picker, it must respond to the
kGetIconData
request code. The Color Picker Manager sends this request code to obtain information about your color picker's icon family and script code. A color picker typically responds to thekGetIconData
request code by calling a color picker-defined subroutine (for example,MyGetIconData
) to handle the request.
pascal ComponentResult MyGetIconData ( PickerStorageHndl storage, PickerIconData *data);
storage
- A handle to your color picker's global data.
data
- A pointer to a
PickerIconData
structure (page 2-17) returned by your color picker. In thescriptCode
field of this structure, your color picker should return its script code, and in theiconSuiteID
field, your color picker should return the resource ID of its icon family.DISCUSSION
YourMyGetIconData
function should return the data that the Color Picker Manager needs to display your picker in the More Choices list--specifically the script code for its name and the resource ID of your color picker's icon family. See the chapter "Finder Interface" in Inside Macintosh: Macintosh Toolbox Essentials for information about icon families.Your function should return
noErr
if successful, or an appropriate result code otherwise.SEE ALSO
Listing 2-26 (page 2-43) in Advanced Color Imaging on the Mac OS illustrates how to implement this function.