How can I change the background color of a button WinAPI C++

后端 未结 4 1416
时光说笑
时光说笑 2020-12-05 08:49

I have searched this many times, but everything I find is MFC. I want it in C++ WinAPI. I know how to change the style of a button control, but I cannot find out how to ma

4条回答
  •  予麋鹿
    予麋鹿 (楼主)
    2020-12-05 09:09

    You need an owner-drawn button for that. For some reason, unlike other controls, regular buttons don't react to changes made in WM_CTLCOLORBTN message handler.

提交回复
热议问题