I defined 2 shapes (actually it should be outline of a shape), like below: MDShapes.RoundRect = new Shape( new ElementTemplate[] { new RoundRectangleTemplate(0, 0, 100, 100, 8) }, FillMode.Winding); MDShapes.ActivityAccept = new Shape( new ElementTemplate[] { new LineTemplate(0, 0, 100, 0), new LineTemplate(100, 0, 100, 100), new LineTemplate(100, 100, 0, 100), new LineTemplate(0, 100, 8, 50), new LineTemplate(8, 50, 0, 0) }, FillMode.Winding);
The first one is round rectangle. then i defined 2 node, assign RoundRect to one node, and assign ActivityAccept to another when. Then save diagram to string and load the string to diagram again. round recttangle changed to rectangle and ActivityAccept is still same.
if I assign Shapes.RoundRect to node, then it can be same shape when reload string to diagram. That's why ? how to resolve it?
Thanks a lot.
|