public class CtrlRoundPictureBox : PictureBox
{
protected override void OnCreateControl()
{
GraphicsPath gp = new GraphicsPath();
gp.AddEllipse(this.ClientRectangle);
Region region = new Region(gp);
this.Region = region;
gp = null;
region = null;
base.OnCreateControl();
}
}
C#自定义圆形PictureBox控件
最新推荐文章于 2023-09-24 10:55:10 发布