vs2010 MFC radio button 不能改变字体颜色?
以前(< vs2008)在OnCtlColor中设置DC的字体颜色都能达到预期效果。vs2010(>= vs2008)中就不可以,希望遇到相同问题的朋友指点个好的方法(不重绘的情况下)。谢谢。
竹中半兵卫
12 years, 7 months ago
Answers
好像必须要用Owner Draw才行
MSDN:
The system sends a WM_CTLCOLORBTN message to a button's parent window before drawing a button. This message contains a handle to the button's device context and a handle to the child window. The parent window can use these handles to change the button's text and background colors.
However, only owner-drawn buttons respond to the parent window processing the message.
sara.
answered 12 years, 7 months ago