 
            | ImageGear Professional v18.1 > API Reference Guide > Core Component API Reference > Core Component Functions Reference > Display Functions > IG_dspl_foreground_set | 
This function sets the foreground color.
| 
                        Copy Code
                     | |
|---|---|
| 
AT_ERRCOUNT  ACCUAPI  IG_dspl_foreground_set(
        [IN] HIGEAR hIGear,
        [IN] DWORD dwGrpID,
        [IN] const LPAT_RGB lpFrColor
);
 | |
| Name | Type | Description | 
| hIGear | HIGEAR | ImageGear handle of an image. | 
| dwGrpID | DWORD | Identifier of the group in which to set options. | 
| lpFrColor | const LPAT_RGB | The new value of FrColor to set. If NULL, then this parameter is ignored. | 
Returns the number of ImageGear errors that occurred during this function call.
All pixel formats supported by ImageGear Professional.
| 
                        Copy Code
                     | |
|---|---|
| HIGEAR hIGear; /* HIGEAR handle of image */ DWORD nGrpID; /* display group identifier */ AT_RGB FrColor; ... FrColor.r = FrColor.g = FrColor.b; IG_dspl_foreground_set( hIGear, nGrpID, &FrColor ); ... | |