How to draw a Windows button in WM_PAINT?

277 Views Asked by At

I'd like to build a custom Windows button without subclassing it.

I simply want to draw it, like I would draw a rectangle by calling FillRect().

How do I call the window procedure registered by the BUTTON window class that performs the painting?

update

As noted in the comments, I want to draw an image that looks like a button without having a child window that is a button.

1

There are 1 best solutions below

0
Alex On BEST ANSWER

By Andreas Rejbrand:

Old style: DrawFrameControl. New style: DrawThemeBackground, DrawThemeText, etc.