ToolBar question

How to create toolbar with non rectangle buttons and different backgrown.
Who is Participating?
fl0ydConnect With a Mentor Commented:

    There are two parts to your question. Customizing the background to your needs isn't all that hard. All you need to do is override the OnEraseBknd-function. To do so, use the ClassWizard (tm), select the toolbar and doubleclick the WM_ERASEBKGND message. The OnEraseBknd-fxn provides you with the necessary CDC to do all your drawing.

    I don't know how to change the button shape, though. I'm not sure if it is possible at all. All I can give you is a general outline of what you need to do. There are two steps involved. First, you need to retrieve either a CWnd* or a HWND for each button on the toolbar. Once you have that, call the SetWindowRgn to specify the buttons' shapes.

Vinayak KumbarSr Program ManagerCommented:

Go to the following link.

U may get some useful samples.
Try it out.
Nightmare090197Author Commented:
I have seem that, nothing about my question.
Nightmare090197Author Commented:
Thanks for good idea :)
All Courses

From novice to tech pro — start learning today.