定义时候 可以定义颜色宽度Pen redPen = new Pen(Color.Red, (float)1);注意宽度小于1默认还是1.不能再小了。如果定义时候没有定义颜色和宽度 redPen.Color = Color.Red;redPen.Width = 1;就这么设定就行啦线类型的什么的都能改。