L_AutSetPaintBkColor

#include ltaut.h

L_LTAUT_API L_INT L_AutSetPaintBkColor (pAutomation, rcBKColor)

pAUTOMATIONHANDLE pAutomation;

pointer to an automation handle

COLORREF rcBKColor;

new background color

Sets the paint automation background color.

Parameter

Description

pAutomation

Pointer to an automation handle.

rcBKColor

The COLORREF value that specifies the new background color.

Returns

SUCCESS

The function was successful.

< 1

An error occurred. Refer to Return Codes.

Comments

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 some selected region from the bitmap.

The default color is RGB (0, 0, 0).

Required DLLs and Libraries

LTAUT

For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application

See Also

Functions:

L_AutCut; L_AutDelete, L_AutGetPaintBkColor.

Topics:

Automation Functions: Automation Paint Property.

Example

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 ; 
   } 
} 

Help Version 19.0.2017.10.27
Products | Support | Contact Us | Copyright Notices
© 1991-2017 LEAD Technologies, Inc. All Rights Reserved.
LEADTOOLS Container and Automation C API Help