Shape.RefreshData() breaks shape from master with NURBS geometry

I’m evaluating Aspose.Diagram for Dotnet (Nuget version 25.1.0) and have trouble with a master shape which has a geometry with a NURBS coordinate.

Let’s assume I have a .vsdx file with one master, which has a shape with no geometries so far. The idea is that I import that master, add it to a new diagram and append new geometries. After that, I create a new instance shape of that master in the same diagram file and call .RefreshData() on that shape.

Expectation: The shape looks exactly like the shape in the master.
Actual: The geometry with a NURBS coordinate breaks other geometries of the same shape.

Example:

var masterDiagram = new Diagram("EmptyMaster.vsdx");
const string masterName = "TheMaster";
var master = masterDiagram.Masters.GetMasterByName(masterName);

var geom1 = new Geom();
geom1.CoordinateCol.Add(new RelMoveTo { X = new DoubleValue(0, MeasureConst.Undefined), Y = new DoubleValue(0, MeasureConst.Undefined) });
geom1.CoordinateCol.Add(new RelLineTo { X = new DoubleValue(0.1, MeasureConst.Undefined), Y = new DoubleValue(0.2, MeasureConst.Undefined) });
geom1.CoordinateCol.Add(new RelLineTo { X = new DoubleValue(0.3, MeasureConst.Undefined), Y = new DoubleValue(0.4, MeasureConst.Undefined) });
master.Shapes[0].Geoms.Add(geom1);

var geom2 = new Geom();
geom2.CoordinateCol.Add(new RelMoveTo { X = new DoubleValue(0, MeasureConst.Undefined), Y = new DoubleValue(0, MeasureConst.Undefined) });
var nurbs = new NURBSTo();
nurbs.X.Ufe.F = "=Width*0.4";
nurbs.Y.Ufe.F = "=Height*0.8";
nurbs.A.Ufe.F = "=0";
nurbs.B.Ufe.F = "=1";
nurbs.C.Ufe.F = "=0";
nurbs.D.Ufe.F = "=1";
nurbs.E.Value = "=NURBS(0.1873,3,0,0,0.4053,0.2009,0,1,0.4059,0.2007,0,1)";
geom2.CoordinateCol.Add(nurbs);
master.Shapes[0].Geoms.Add(geom2);

var diagram = new Diagram();
diagram.Masters.Add(master);
diagram.AddShape(2, 2, masterName, 0);
diagram.Pages[0].Shapes[0].RefreshData();
diagram.Save("BrokenNurbs.vsdx", SaveFileFormat.Vsdx);

If I open the BrokenNurbs.vsdx file, the master looks like expected:
1_Master.jpg (110.0 KB)

But the shape looks like this:
2_Shape.jpg (177.4 KB)

As you can see, the NURBSTo from Geometry 2 was copied into Geometry 1 when .RefreshData() was executed.

The described effect gets even crazier when there are multiple genoms with NURBSTo, as you can see in the next picture. On the left side is the master shape, on the right side the corresponding shape after .RefreshData(). Intestringly, there are also many No Formula entries which didn’t exist before as well as the amount of coordinates in the geometries are very different.
3_ManyGeomsWithNurbs.jpg (441.2 KB)

Thanks for the help in advance!

@codingmicha
Thanks for the screenshots.
After an initial testing, I am able to reproduce the issue as you mentioned.

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): DIAGRAMNET-53670

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

The issues you have found earlier (filed as DIAGRAMNET-53670) have been fixed in this update. This message was posted using Bugs notification tool by philip.zhou