Ejemplo n.º 1
0
        public SpiroDrawing FromPlateString(string plate)
        {
            var shapes = SpiroPlate.ToShapes(plate);

            if (shapes != null)
            {
                return(new SpiroDrawing()
                {
                    Width = _drawing.Width,
                    Height = _drawing.Height,
                    Shapes = shapes,
                    Guides = _drawing.Guides
                });
            }
            return(null);
        }
Ejemplo n.º 2
0
        public void ExecuteScript(string script)
        {
            try
            {
                var shapes = SpiroPlate.ToShapes(script);
                if (shapes != null)
                {
                    foreach (var shape in shapes)
                    {
                        _drawing.Shapes.Add(shape);
                        RunSpiro(shape);
                    }

                    _invalidate();
                }
            }
            catch (Exception ex)
            {
                Debug.WriteLine(ex.Message);
                Debug.WriteLine(ex.StackTrace);
            }
        }
Ejemplo n.º 3
0
 public string ToPlateString()
 {
     return(SpiroPlate.FromShapes(_drawing.Shapes));
 }