views:

116

answers:

1

I have a small (6x9) graphic that I want to draw on a CButton. I have managed to get this to work using ::LoadImage and CButton::SetBitmap. The problem is that when I put the bitmap on the button it is no-longer drawn as an 'XP style' button. I.e. it does not have rounded corners.

How can I draw a bitmap (or an icon) on a button without the button losing the XP style?

+2  A: 

Don't do it with owner draw. Use CMFCButton which has much better support for bitmapped buttons, even with transparency.

Roel
Also needed the following link in OnInitDialog to work:CMFCVisualManager::SetDefaultManager(RUNTIME_CLASS(CMFCVisualManagerWindows));
Hoppy