Drawing Venn Diagrams on C# form

This post is for drawing Venn Diagrams on a form as mentioned in the title. It is really easy but I needed this in one of my projects and with c# it is really simple…




private void Form1_Paint(object sender, PaintEventArgs e)

 Brush oz=new SolidBrush(Color.White);
 Pen kal=new Pen(oz,10);
 PointF nokta=new PointF(20,50);
 Font ye=new Font("Times New Roman",12);

 PointF nokta2 = new PointF(90, 50);        
 e.Graphics.DrawString("S", ye, oz, nokta2);

 PointF nokta3 = new PointF(160, 50);
 e.Graphics.DrawString("M", ye, oz, nokta3);

 e.Graphics.DrawEllipse(Pens.White, 90, 50, 100, 100);
 e.Graphics.DrawEllipse(Pens.White, 160, 50, 100, 100);


kick it on DotNetKicks.com

About these ads