65 Custom Properties are not preserved? - yEd Q&A
Welcome to yEd Q&A!
Here you can ask questions and receive answers from other members of the community and yEd developers. And you can tell us your most wanted feature requests.

Categories

Custom Properties are not preserved?

0 votes
We need a .xgml as file type.
We have custom properties that are included in a .xgml.

Opening them with Yed does not make them show up in the properties view even if they are well formatted
(<attribute id="NewAttribute" type="string">NewValue</attribute>).
They should be at minimum in the data section. Yed should not interpret anything unless told otherwise.

These are raw data values that should be attached and not be interpreted by the program.

- Saving them as .xgml again will not preserve them and will delete them without any warning.
- Adding the custom properties manually through the menuing will just create new ones instead of linking the existing data. This solution will not even persist onto the saved file, which is kind of annoying and very confusing how this should be preserved easily by the simple use of tag language.
- Having a .cnfg is not really useful and should not be needed for such a simple process (it is literally very simple tag language)
- Making it a .graphml is not what we need for our use.

Could we please have Yed preserve custom properties even if they are not to be interpreted? I am genuinely surprised this is not default behavior. It seems like having to use multiple files or other extensions is both overhead and unecessary.
in Feature Requests by

1 Answer

0 votes

yEd supports (de-)serializing custom properties only with its GraphML file format.

All other graph exchange formats in yEd (i.e.YGF, GML, XGML, and TGF) are legacy formats that are not updated with improvements anymore. This has been the case for a very long time (I think well over ten years).

This leaves you the following options:

  1. Open your XGML files in yEd, manually add your custom properties (see "Edit" -> "Manage Custom Properties"), save your diagram to GraphML, and work with GraphML from then on.
  2. Create an XSLT stylesheet that transforms your XGML documents into GraphML documents and use yEd's support for "XML + XSL" to open your XGML files through your stylesheet. If your stylesheet properly reproduces your custom properties in the resulting GraphML document, your custom properties will be available in yEd. If you want to edit the resulting diagram (especially custom property values), you will have to save your diagram in GraphML format.
  3. Use yEd as an XGML viewer application only.

That said, I do not understand what you mean by "having a .cnfg is not really useful and should not be needed for such a simple process". yEd does not use that file name extension. (yEd offers the possibility to export properties mapper configurations to *.cnfx files, but these files do not store any graph information at all.)

by [yWorks] (163k points)
Legal Disclosure | Privacy Policy
...