ApplyCallbackFunction

[This is preliminary documentation and subject to change.]

The function ApplyCallbackFunction is a callback function which updates the ICM configuration data while the dialog box displayed by the SetupColorMatching function is executing. The name ApplyCallbackFunction is a placeholder. The actual name of this callback function is supplied by the application using ICM.

BOOL ApplyCallbackFunction(
  COLORMATCHSETUP *pColorMatchSetup,
  LPARAM lParam
);
 

Parameters

pColorMatchSetup
Pointer to a COLORMATCHSETUP structure that contains ICM configuration data.
lParam
Contains a value supplied by the application.

Return Values

If this function succeeds, the return value is TRUE.

If this function fails, the return value is FALSE. For extended error information, call GetLastError.

Remarks

The ApplyCallbackFunction function is used to change the ICM configuration for a device while the Color Management dialog box is displayed. The Color Management dialog box is displayed by the SetupColorMatching function.

If the callback function is provided, an Apply button is displayed in the lower right of the dialog box. When you select the Apply button, the callback function immediately updates the configuration for the device being set up. The Color Management dialog box remains on the screen.

An application supplies a callback function to ICM by storing the address of the callback function in the COLORMATCHSETUP structure that is passed to the SetupColorMatching function. The address is stored in the lpfnApplyCallback member of the COLORMATCHSETUP structure. The dwFlags member should be set to CMS_USEAPPLYCALLBACK, or the callback function will be ignored.

A value supplied by the application may be passed to the callback function. Prior to invoking the SetupColorMatching function, the application can store a value in the lParamApplyCallback member of the COLORMATCHSETUP structure. When the callback function is invoked, the value in the lParamApplyCallback structure member will be passed to the callback function in its lParam parameter.

The callback function is completely optional. If it is not supplied, the Apply button does not appear in the Color Management dialog box.

QuickInfo

  Windows NT: Requires version 5.0 or later.
  Windows: Requires Windows 98.
  Windows CE: Unsupported.
  Header: Declared in wingdi.h.
  Import Library: Use gdi32.lib.

See Also

Color Management Overview, ICM 2.0 Functions, SetupColorMatching, COLORMATCHSETUP