title: Button background transparency using Win32 and Visual Styles
body: <p><em><strong>Edit:</strong> If anyone's tried this in win32 before, am I going in the right direction by using DrawThemeBackground()?</em></p>
  
  <p>I'v recently enabled Visual Styles using a manifest for version 6 of ComCtl32.dll.  Example of Visual Styles in Win32: <a href="http://msdn.microsoft.com/en-us/library/bb773187(VS.85).aspx" rel="nofollow noreferrer">Visual Styles</a></p>
  
  <p>The buttons look great, but I can't figure out how to make the background around the buttons transparent.  Please see example image: <a href="http://www.freeimagehosting.net/image.php?2bdeff33ba.jpg" rel="nofollow noreferrer">http://www.freeimagehosting.net/image.php?2bdeff33ba.jpg</a></p>
  
  <p>My main window background color is set to dark grey with:</p>
  
  <pre><code>a.hbrBackground = GetStockObject(DKGRAY_BRUSH);
  </code></pre>
  
  <p>The common controls are initialized with:</p>
  
  <pre><code>INITCOMMONCONTROLSEX stylesStruct;
  stylesStruct.dwSize = sizeof(stylesStruct);
  stylesStruct.dwICC = ICC_STANDARD_CLASSES;
  InitCommonControlsEx(&amp;stylesStruct);
  </code></pre>
  
  <p>And I create the button windows with:</p>
  
  <pre><code>j = CreateWindow(L"BUTTON", L"hello",
      WS_VISIBLE | WS_CHILD | BS_DEFPUSHBUTTON, 100, 100,
      100, 100, h, 0, hInst, 0);
  </code></pre>
  
  <p>Buttons look fine over a white background, but the border becomes visible over anything else. Is it possible to make the border around buttons transparent?  </p>