We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Inheritance from a master shape- how should it work?

Hello,

The Visio API has two methods for accessing the shapesheet. Cells and CellsSRC. Both return a cell regardless of it is inherited from a master shape (Document Stencil) or if it defined on a instance of a shape. The methods CellExists and CellsSRCExist allow you to investigate if it is inherited or not.

The Aspose API has typed collections that represent sections. For example, Geoms and Props. The behaviour of how they handle inheritance from as master shape is not clear from any documentation nor consistently implemented across sections of the shapesheet.

Shape.Geoms
- Only exists in master, unless a cell is overridden locally, at which point, entire geoms collection is available locally
- Values are merged from master / local overrides
- Del flag is set when a section is deleted locally

Shape.Props
- Exists locally regardless of if anything is overridden
- Values are merged from master / local overrides
- Del flag doesn't appear to be set, so any property deleted locally still exists locally with Del = Undefined.

As you can see from the two examples above, how they handle inheritance is different, so one of them is a bug. Also the Prop.Del flag appears to be a bug as well.

I've attached a command line app as an example of the behaviour. This was tested on a VSDX.

Regards,

Andrew


Hi Andrew,


Thank you for contacting support. We are working over your query and will get back to you soon.

Hi Andrew,


Thank you for contacting support. We have logged an investigation to improve the implementation of said sections of the shapesheet under ticket ID DIAGRAMNET-51232 in our bug tracking system. We have also linked your post to this ticket and will let you know, once the significant progress has been made. We are sorry for the inconvenience caused.

Hello Imran,

I highlighted an inconsistency between implementations as well as a problem with property Del field. What does the defect correspond to and what is the intended behavior with inheritance.

Regards,

Andrew

Hi Andrew,


Thank you for the inquiry. We are in communication with our product team. We may log a separate ticket for Del field property and will get back to you in early next week with answers to your questions.

Hello Imran,

Do you have an update on this?

Regards,

Andrew

Hi Andrew,


Thank you for the inquiry. Our product team needs to investigate it more in details and later they will share their findings. We will let you know once any further update is available from our product team.

Hi Andrew,


Thank you for being patient. In reference to the ticket ID DIAGRAMNET-51232, we have resolved the problem of property Del field. The fix for this problem will be included in the next version 17.5 of Aspose.Diagram API. The problem of inconsistency between implementations is still in the analysis phase. We will let you know once a significant progress has been made in this regard.

Hello Imran,

Just to add to my earlier examples, I now have a third inheritance behaviour.

andrew.ridgeley:

Shape.Geoms
- Only exists in master, unless a cell is overridden locally, at which point, entire geoms collection is available locally
- Values are merged from master / local overrides
- Del flag is set when a section is deleted locally

Shape.Props
- Exists locally regardless of if anything is overridden
- Values are merged from master / local overrides
- Del flag doesn’t appear to be set, so any property deleted locally still exists locally with Del = Undefined.


Shape.Hyperlinks
- Only exists in master, unless a cell is overriden locally, at which point, only the overriden row is available on the instance
- Only overriden cell has a value in the local row, any columns that should be inherited from a master are empty
- Del flag doesn’t appear to be set, so any hyperlink deleted locally still exists locally with Del = Undefined.

Hi Andrew,


Thank you for the details. We have recorded this third inheritance behavior under the ticket ID DIAGRAMNET-51232 in our issue tracking system.

Hi Andrew,


Thank you for being patient. In reference to third inheritance behavior under the ticket ID DIAGRAMNET-51232, we have resolved the problem of Del flag of hyperlink. The fix for this problem will be included in the next version 17.5 of Aspose.Diagram for .NET API.

DIAGRAMNET-51232 - Prop.Del is resolved in 17.5
Hyperlink.Del still an issue in 17.5

Hi Andrew,


Thank you for the confirmation. We have logged this information under the ticket ID DIAGRAMNET-51232 in our bug tracking system. We will let you know once it is resolved.

User.Del always returns undefined.

Also, I am still waiting for a response from the dev team ahout how shapesheet inheritance should work in Aspose.

Hi Andrew,


Thank you for the inquiry. Our product team has resolved this ticket (ID: DIAGRAMNET-51232). They have implemented enhancements for shapesheet inheritance as well as included the fix of User.Del value. If there is no issue in the quality assurance phase, then this fix will be included in the next version 17.6 of Aspose.Diagram for .NET API. Furthermore, we have logged a request to share details of the fix and will let you know once an update is available.

Hi Andrew,


Thank you for being patient. In reference to the ticket ID DIAGRAMNET-51232, please download and try this latest Hotfix version: Aspose.Diagram for .NET 17.5.1. Please also let us know how that goes on your side.

Hello,

Resolved: Master hyperlinks deleted locally

Unresolved:-
- Master user cells deleted locally
- Master hyperlinks overriden locally only have values for overriden cells. Any inherited cells are read as empty string.

Hi Andrew,


Thank you for the confirmation. We have reopened already logged ticket ID DIAGRAMNET-51232 and also intimated our product team. We will let you know once it is fixed. We are sorry for the inconvenience.

I am still waiting for a response from the dev team on how inheritance should work, and would like a status update on DIAGRAMNET-51232.

Regards,

Andrew

@andrew.ridgeley,
Thank you for the inquiry. Unfortunately, there is no update on this yet and our product team is in progress to resolve this ticket. We have intimated our product team and let you know once a significant progress has been made in this regard.

Best Regards,
Imran Rafique