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

Edge label text adds extra white space on reload

0 votes

If I remove the extra space and just write c(a1), the box fits the size nicely. However, I save and exit and then reload, this extra space reappears cluttering the entire view.

Here is the corresponding GraphML file

 

in Help by (120 points)
edited by

Which version of yEd are you using (see "Help" -> "About")?
Which version of Java are you running yEd on (again see "Help" -> "About")?
Can you upload a sample GraphML file that exhibits the problem here? (See How to upload files to yEd Q&A? for details on uploading files here.)

yEd Version 3.17.2
Java Version: 1.8.0_131 Java VM: Java HotSpot(TM) 64-Bit Server VM, Oracle Corporation
Link to the GraphML file has been added to the main question.

I cannot reproduce this problem.

I downloaded your file, selected the top left edge, clicked the "..." button from the edge's "Text" property, removed all the whitespace, saved the file, re-started yEd, and re-opened the file. No extra whitespace reappeared - the text was exactly as saved. I also tried all other text editing methods yEd offers and it always worked as expected.

Are you sure you are actually saving your edits? And if so, are you sure you are opening the modified file and not the original, unmodified one? Moreover, have you tried saving your edits to a new file instead of overwriting the original file?

This is the result of my edits (I changed the line color of the edited edge to red).

I was working on 3.13 and recently updated to 3.17.2. I can reproduce this on 3.13 (changing placement attribute to Smart and then back to Centered). Then the saved file opens on 3.17.2 with the issue inherited. But, editing on 3.17.2 seems to resolve the issue.

Anyways, it is working fine now

1 Answer

0 votes

I can reproduce this problem.  Here is my 'About yEd':

Version 3.19.1.1
Powered by the yFiles Graph Visualization Library
http://www.yWorks.com
Copyright 2000-2020 yWorks GmbH. All Rights Reserved.

Java Version: 14.0.1
Java VM: OpenJDK 64-Bit Server VM, AdoptOpenJDK
 

by
Thank you very much for pointing this out.

As it turns out, writing text in mixed-content XML elements is broken in Java 14 (yet again). In other words, this issue occurs only when running yEd on Java 14. With Java 13, this problem does not occur.

We will try to find a fix of course, but in the meantime I suggest to stay on Java 13.
Legal Disclosure | Privacy Policy
...