Sets the paint automation background color.
#include "ltaut.h"
L_LTAUT_API L_INT L_AutSetPaintBkColor (pAutomation, rcBKColor)
Pointer to an automation handle.
The COLORREF value that specifies the new background color.
| Value | Meaning |
|---|---|
| SUCCESS | The function was successful. |
| < 1 | An error occurred. Refer to Return Codes. |
Note: This function is only available in the Digital Paint toolkits.
This function will only work if the automation handle was created using the AUTOMATION_MODE_PAINT automation mode. For information on creating an automation handle, refer to L_AutCreate.
This color will be used by the automation to fill the area left behind when the user cuts or deletes a selected region from the bitmap.
The default color is RGB (0, 0, 0).
This example will make sure that the BK is not anything but black.
L_INT AutSetPaintBkColorExample(pAUTOMATIONHANDLE pAutomation){L_INT nRet;nRet = L_AutIsValid ( pAutomation );if ( SUCCESS == L_AutIsValid ( pAutomation ) ) /* check the validity of the automation handle */{COLORREF crBkColor ;/* get the current paint automation color */nRet = L_AutGetPaintBkColor ( pAutomation, &crBkColor ) ;if(nRet != SUCCESS)return nRet;if ( crBkColor != RGB ( 0, 0, 0 ) ) /* check if its not black */{/* set the paint automation background color */nRet = L_AutSetPaintBkColor ( pAutomation, RGB(0, 0, 0 ) ) ;if(nRet != SUCCESS)return nRet;}return SUCCESS ;}else{return nRet ;}}