Bug 259822 - [Ecore Diagram] Restore Related Elements shouldn't apply layout
Summary: [Ecore Diagram] Restore Related Elements shouldn't apply layout
Status: RESOLVED FIXED
Alias: None
Product: Ecoretools
Classification: Modeling
Component: General (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows Vista
: P3 normal
Target Milestone: 2.0.0   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2008-12-31 08:53 EST by Alain Picard CLA
Modified: 2014-04-29 12:14 EDT (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alain Picard CLA 2008-12-31 08:53:18 EST
Build ID: I20081217-1605 

Steps To Reproduce:
1. Select a node on the diagram
2. Right-click and choose Navigate then Restore related elements
3. The related nodes are shown (great), but the diagram is relaid out (bad)


More information:
Most often when we have nicely laid out diagrams and are just adding new nodes, this completely ruins our manually crafted layout and forces us to add the related nodes manually and risk forgetting some, or to completely redo the layout again. 
This action should just show the related elements in a default location and let us complete the layout. At the very least it should not affect unrelated nodes during a limited layout operation
Comment 1 Alain Picard CLA 2008-12-31 08:53:52 EST
FYI, this is emf-cdo-SDK-2.0.0M4
Comment 2 Ed Merks CLA 2008-12-31 08:58:10 EST
I noticed this problem recently as well.  It's very frustrating and there's no other way to get the hidden things back in view. :-(
Comment 3 Jacques LESCOT CLA 2009-03-30 11:53:59 EDT
The "Arrange All" action is not acceptable in this case (indeed, we do not want to completely re-arrange existing elements that may have been manually located).
The "Arrange Selection" action would be sufficient, but it should be applied on newly added nodes only. We need to change the RestoreRelatedLinksAction class (and particularly in the run() method) to fix this.
To be complete, we should let the user choose whether he wants to automatically run the "Arrange" action or not : this could be done through a popup dialog "linked" with a preference. The first time the "Restore Related Elements" is launched, a dialog is prompted so that the user is able to choose whether he wants to "Arrange related elements" or not (This will be stored in a preference). A checkbox allows to prevent the dialog to appear again later (This is stored in a preference again).
Comment 4 Matteo Risoldi CLA 2012-02-23 05:34:40 EST
+1 to comment 3; the usefulness of diagrams is mostly for illustration purposes, and manual layout is generally required in order to get a nice looking readable diagram. After spending hours to layout a diagram nicely, I don't want to redo all the work in subsequent revisions just because Ecore can't automatically display all the modifications of the metamodel in the diagram and I'm obliged to restore related elements and it messes everything up! An option to completely avoid the rearrangement of the graph is a must!
Comment 5 Adrian Price CLA 2012-11-28 04:40:49 EST
We (TIBCO) find the Ecore Tools incredibly useful and I commend the authors for their fine work.

However, I wholeheartedly endorse these comments. It is soul destroying and infuriating to have spent a lot of time carefully laying out a diagram only to have the tool trash your work. This happens time and time again and has cost us many hours of wasted effort.

A suggestion: separate the adjustments to existing graphical elements into a separate command so that UNDO can restore the original layout but with the 'related links' still in place. Then all that would be required is some judicious placement of the added elements.
Comment 6 Cedric Brun CLA 2014-01-06 08:34:57 EST
This is fixed with EcoreTools 2.0.

Also note that "Restore Related Elements" is now labelled "Add Related Elements".