Example #1
0
 public static void CreateRegion(Control control, Rectangle rect)
 {
     using (GraphicsPath path =
                GraphicsPathHelper.CreatePath(rect, 8, RoundStyle.All, false))
     {
         if (control.Region != null)
         {
             control.Region.Dispose();
         }
         control.Region = new Region(path);
     }
 }