Creating a control like this
How could I create a control that looks like this one:
http://img195.imageshack.us/img195/4268/eeeea开发者_高级运维e.png http://img195.imageshack.us/img195/4268/eeeeae.pngI just want that small end. Thanks
If that's a Windows ComboBox control with a visual style applied to it, you can render its themed button wherever you like using DrawThemeBackground()
and CP_DROPDOWNBUTTON
.
In your WndProc handle the WM_PAINT message. The easiest way using GDI is to have a ready to use image in your resources to load and drow on the window's DC. Little bit more complicated is to use GDI+, where you can draw rounded corners using Path object and gradient background using LinearGradientBrush.
精彩评论