Example #1
0
 private void RoundedButton_Resize(object sender, EventArgs e)
 {
     RoundedRectangleRegion rndRectRegion = new RoundedRectangleRegion();
     this.Region = rndRectRegion.GetRoundedRect(new RectangleF(this.ClientRectangle.Left, this.ClientRectangle.Top, this.ClientRectangle.Width, this.ClientRectangle.Height), 8);
 }
Example #2
0
 /// <summary>
 /// Creates an instance of the class
 /// </summary>
 public RoundedButton()
 {
     RoundedRectangleRegion rndRectRegion = new RoundedRectangleRegion();
     this.Region = rndRectRegion.GetRoundedRect(new RectangleF(this.ClientRectangle.Left, this.ClientRectangle.Top, this.ClientRectangle.Width, this.ClientRectangle.Height), 8);
     this.Resize += new EventHandler(RoundedButton_Resize);
 }