public BorderedRectangle(Canvas cvs) : base(cvs) { rect.Fill = new SolidColorBrush(RandomColorGenerator.RandomColor()); rect.StrokeDashArray = new DoubleCollection { 4.0, 2.0 }; rect.Stroke = new SolidColorBrush(Colors.Black); }
public ShapeRectangle() { rect = new Rectangle(); rect.Height = rnd.Next(40, 50); rect.Width = rnd.Next(80, 100); rect.StrokeThickness = 1; rect.MouseLeftButtonDown += onMouseDown; rect.MouseUp += onMouseUp; rect.MouseMove += onMouseMove; rect.Fill = new SolidColorBrush(RandomColorGenerator.RandomColor()); rect.Stroke = new SolidColorBrush(Colors.Gray); }
public ShapeLine() { line = new Line(); line.StrokeEndLineCap = PenLineCap.Triangle; line.StrokeThickness = 3; _myColor = RandomColorGenerator.RandomColor(); line.Stroke = new SolidColorBrush(_myColor); lR = new Line(); lL = new Line(); lR.Stroke = new SolidColorBrush(_myColor); lL.Stroke = new SolidColorBrush(_myColor); lR.StrokeThickness = 3.00; lL.StrokeThickness = 3.00; }