Exemplo n.º 1
0
        public BasicShape AddShape(Point position, int id, int routeId, TemplateDot templateDot)
        {
            BasicShape shape = new BasicShape(templateDot, position, id, routeId);

            this.DiagramView.Children.Add(shape);

            return(shape);
        }
Exemplo n.º 2
0
        public ShapeConnectorBase AddConnection(BasicShape source, BasicShape target, int id, int routeId)
        {
            ShapeConnectorBase conn = new ShapeConnectorBase();

            conn.SetBinding(ShapeConnectorBase.StartPointProperty, CreateConnectorBinding((IConnectable)target));
            conn.SetBinding(ShapeConnectorBase.EndPointProperty, CreateConnectorBinding((IConnectable)source));
            conn.StartDot = target;
            conn.EndDot   = source;
            conn.SetToolTip();
            conn.ConnectorId = id;
            conn.RouteId     = routeId;

            this.DiagramView.Children.Insert(0, conn);

            return(conn);
        }
Exemplo n.º 3
0
 public void RemoveShape(BasicShape removingShape)
 {
     this.DiagramView.Children.Remove(removingShape);
 }
Exemplo n.º 4
0
        public BasicShape AddShape(BasicShape shape)
        {
            this.DiagramView.Children.Add(shape);

            return(shape);
        }