Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LayoutEngine/ELK layouting does no work well with custom source models #1173

Open
tortmayr opened this issue Nov 23, 2023 · 2 comments
Open
Labels
bug Something isn't working server-java server-node

Comments

@tortmayr
Copy link
Contributor

see #1168

@tortmayr tortmayr added the bug Something isn't working label Nov 23, 2023
@tortmayr tortmayr added this to the ELK Layouting improvements milestone Apr 15, 2024
@planger
Copy link
Member

planger commented May 13, 2024

Sketch of a potential solution:

  • Run auto-layouting as is. This will update the GModel directly.
  • Walk through the GModel elements and create a ChangeBoundsOperation containing the new position of each element with bounds
  • Similarly, create ChangeRoutingPointsOperation for routing points of SRoutableElementImpl instances
  • Use the action dispatcher to dispatch all created change bounds and change routing point operations

This will allow reusing the diagram-specific implementations of those operations so the position and routing point changes would correctly end up in whatever source model is being used.

The behavior sketched above should probably be done in the LayoutOperationHandler after it has called layout().

@tortmayr
Copy link
Contributor Author

Side note: some default implementations for handling the ChangeBoundAction might not suited to handle this use case.
e.g. the EMFChangeBoundsOperationHandler currently only handles top-level shapes. So layout information of ports and or sub-labels would get lost.

@tortmayr tortmayr removed this from the ELK Layouting improvements milestone Sep 18, 2024
@planger planger removed their assignment Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working server-java server-node
Projects
None yet
Development

No branches or pull requests

2 participants