public override Primitive Clone() { EllipseShape ellipse = new EllipseShape(this.rect); ellipse.FillColor = this.FillColor; ellipse.LineWidth = this.LineWidth; ellipse.BorderColor = this.BorderColor; return ellipse; }
public void AddRandomEllipse(int width = 100, int height = 200) { Random rnd = new Random(); int x = rnd.Next(5, 1500); int y = rnd.Next(5, 750); EllipseShape ellipse = new EllipseShape(new Rectangle(x, y, width, height)); ellipse.FillColor = MainForm.GetRandomColor(); ellipse.BorderColor = MainForm.GetRandomBorderColor(); if (Program.form.TabControl.SelectedTab.Equals(Program.form.TabPage3)) PrimitiveList3.Add(ellipse); else PrimitiveList.Add(ellipse); selection = ellipse; }
public EllipseShape(EllipseShape ellipse) : base(ellipse) { }