C# 绘制窗体边框(Form_Paint事件)
C# 绘制窗体边框源码
C# 全选
private void frmBase_Paint(object sender, PaintEventArgs e)
{
this.DrawFormBorder(e.Graphics);
}
C# 全选
/// <summary>
/// 绘制窗体边框
/// </summary>
/// <param name="g"></param>
protected void DrawFormBorder(Graphics g)
{
ControlPaint.DrawBorder(g, this.ClientRectangle,
Color.Black, 1, ButtonBorderStyle.Solid, //左边
Color.Black, 1, ButtonBorderStyle.Solid, //上边
Color.Black, 1, ButtonBorderStyle.Solid, //右边
Color.Black, 1, ButtonBorderStyle.Solid);//底边
}
效果
版权声明:本文为开发框架文库发布内容,转载请附上原文出处连接
csframework.workflow C/S框架网