Windows API一日一练(25)CreateSolidBrush函数
<iframe align="center" marginwidth="0" marginheight="0" src="http://www.zealware.com/csdnblog336280.html" frameborder="0" width="336" scrolling="no" height="280"></iframe><div class="postText"><div style="margin: 0cm 0cm 0pt 36pt;">当你看到Windows显示的按钮时,背景颜色是灰色的。当你看到缺省的窗口背景时,它是白色的。当你的老板需要你创建一个黑色背景的按钮时,你会怎么样做呢?其实在Windows里先用API函数CreateSolidBrush创建画刷,然后调用FillRect函数来填充背景。这样来,不管你需要什么样的背景,都随心所欲了吧。现在先来搞懂CreateSolidBrush函数,下次再来练习FillRect。
页:
[1]