public Paint() { InitializeComponent(); currentMode = NameForShapeFactory.Curve; _currentBitmap = new Bitmap(800, 600); IShape currentShape = new Curve(); currentShape.Thickness = _currentBrashSize; currentShape.Color = _currentColor; shapeList.Add(currentShape); numericUpDown1.Value = 1; pictureBoxMain.Image = _currentBitmap; tempBitmap = new Bitmap(_currentBitmap); graphics = Graphics.FromImage(tempBitmap); }
public AbstractShape(NameForShapeFactory name) { this.name = name; }
private void DotButton_Click(object sender, EventArgs e) { currentMode = NameForShapeFactory.Dot; }
private void EllipseButton_Click(object sender, EventArgs e) { currentMode = NameForShapeFactory.Ellipse; }
private void RectangleButton_Click(object sender, EventArgs e) { currentMode = NameForShapeFactory.Rect; }
private void CurveButton_Click(object sender, EventArgs e) { currentMode = NameForShapeFactory.Curve; }