ZeeImage Control Message

ZIM_SETBGCOLOR


ZIM_SETBGCOLOR

An application sends a ZIM_SETBGCOLOR to set the background color of ZeeImage image list control client area.

ZGM_SETBGCOLOR
wParam = (int)slot;             //The slot or index of the image to set the background color
lParam = COLORREF;              //COLORREF value for transparency

Parameters

wParam
The value of wParam. The slot or index of the image in the ZeeImage image list.

lParam
The value of lParam. A COLORREF value to use as the background color for the specified image.

Return Values

This message does not return a value.

Example


SendMessage(himage,ZIM_SETBGCOLOR,2,RGB(255,255,0));

Note:

Images are displayed maintaining the original aspect ratio of the image. This means that either the top and bottom, or the left side and right side of the ZeeImage control client area must be padded to keep the image centered in the client area. The color of this padding is set by this ZIM_SETBGCOLOR message. If the ZeeImage control is created without a border, setting the background color to the same color as the background of the application client area (in conjunction with the transparent color) will create a clean transition from your application background to the image.

Copyright © 2020 by David Hillard