public void DrawLine(Pen pen, int x1, int y1, int x2, int y2) { if (pen == null) throw new ArgumentNullException ("pen"); MoveTo (x1, y1); LineTo (x2, y2); StrokePen (pen); }
public void Draw(Graphics g) { Pen p = new Pen(Color.Green, 1f); g.DrawLine(p, 0, height / 2, width, height / 2); g.DrawLine(p, width / 2, 0, width / 2, height); }