images in tab controls

I have added an image to a tab ctrl through an image map.  The image looks goofy though because it picks up the background color of the window, instead of just staying the color of the tab control.  Any suggestions?
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

Nicolay_ChConnect With a Mentor Commented:
Set image background color exactly color of window...

Nicolay is correct, you should set the image list bk color to be the system bk color.
This is the code which does this:

pfauxAuthor Commented:
this doesn't appear to work right...there is no change to the images background color, even when I change COLOR_WINDOW to COLOR_ACTIVEBORDER, etc.

I even tried setting this when we are adding the image list
m_smlImageList.Add( &m_SmallMap,
   GetSysColor(COLOR_WINDOW) );

and that just causes the background to be a pink color

any suggestions?
pfauxAuthor Commented:
figured it out, here is what I finally did, in the spot where I am inserting the image.

ptr.iImage = 64;

pfauxAuthor Commented:
i'll accept your answer because you are kind of correct.  I did need to set the background but needed to set it to that it would be transparent.  Only found that because the other way did not work.  You did get me into the correct area in the documentation to find the right answer.
All Courses

From novice to tech pro — start learning today.