MyColorChangedFunctionApplication-defined function that handles color changes.
Your application can supply the
colorProcfield of the color picker parameter block with a pointer to the application-defined function. Your function should take two parameters--one for data previously specified by your application, and another specifying the new color selected by the user. For example, this is how you would declare it if you were to name it
pascal void MyColorChangedFunction ( long userData, PMColorPtr newColor);
- Data that your application supplies in the
colorProcDatafield of the color picker parameter block (page 2-20). Your application can use this value for any purpose it needs.
- A pointer to a
PMColorstructure (page 2-15) that contains the new color selected by the user.
DISCUSSIONYour color-changed function should update the user's document to use the color specified in the
SEE ALSOListing 2-3 (page 2-9) in Advanced Color Imaging on the Mac OS provides an example of a color-changed function.