示例#1
0
 public PaintRectangle(ShapePoint location, ShapeSize size)
 {
     _rectangle.Location = location.ToPoint();
     _rectangle.Size     = size.ToSize();
 }
示例#2
0
        public void NewShape(EShapeType type, int thickness, PaintColor color, int cornes, ShapeSize size)
        {
            _newshape           = _shape.CreateShape(type);
            _newshape.Thickness = thickness;
            _newshape.Color     = color;

            if (_newshape is Hexagon)
            {
                (_newshape as Hexagon).Cornes = cornes;
                (_newshape as Hexagon).Size   = size;
            }
            _storage.Add(_newshape);
        }