0
當鼠標移過它時,是否可以爲我的控件顯示外部陰影?在winforms?如何爲自定義控件創建外部陰影
我可以改變它的外觀,但一個影子?
public class MyButton : Button
{
protected override void OnPaint(PaintEventArgs pevent)
{
GraphicsPath path = new GraphicsPath();
path.AddEllipse(0, 0, ClientSize.Width, ClientSize.Height);
this.Region = new Region(path);
base.OnPaint(pevent);
}
}