-
Notifications
You must be signed in to change notification settings - Fork 33
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
[POC] Alternative terminal point implementation for 'no orthogonal segments' #1863
Conversation
…gments' Only use the implementation involving the perimeter projection when there is no waypoint. Otherwise, use the original first and last waypoints. This avoids side effects when terminal waypoints are inside the shapes and - in some cases - outside shapes. Drawbacks: as the terminal waypoints can be inside or outsides shapes, the rendering of such edge cases may be less pretty than before.
🎊 PR Preview b042a98 has been successfully built and deployed to https://process-analytics-bpmn-visualization-js-demo_preview-pr-1863.surge.sh 🕐 Build time: 53.379s 🤖 By surge-preview |
🎊 PR Preview b042a98 has been successfully built and deployed to https://process-analytics-bpmn-visualization-js-doc_preview-pr-1863.surge.sh 🕐 Build time: 46.272s 🤖 By surge-preview |
Kudos, SonarCloud Quality Gate passed! |
add diagrams for expand/collapsed pools and subprocesses page: manage collapse element query parameter test: test the diagram rendering with and without collapsed elements
Decisions taken with @csouchet based on commit 991ab47
|
Issues created, so closing. |
Only use the implementation involving the perimeter projection when there is no waypoint. Otherwise, use the original first and last waypoints.
This avoids side effects when terminal waypoints are inside the shapes and - in some cases - outside shapes.
Drawbacks: as the terminal waypoints can be inside or outsides shapes, the rendering of such edge cases may be less pretty than before.
covers #295
covers #349
covers #715
covers #994
covers #1236
covers #1368
Details and notes
Benefits: this implementation avoids all side effects described in #1779 (comment)
It also fixes #715 and #1368 (see visual non regression test screenshots updated here)
About the created drawbacks: we could later implement a new floating point computation. Get the intersection of the perimeter with the existing last segment instead of doing a projection. That way, the point on the perimeter would be always aligned with the last existing segment and wouldn't create glitches with arrows like #351 (comment) (we have visual non regression test to detect such problems and fixes)
If we go on with this implementation, I will create a specific issue about the new behavior.
On this topic, bpmn-js manages inside terminal waypoints by always putting the shape on top of the edge and use opacity with the shape fill color. mxGraph provides a way to always put shapes on top of edges
See the documentation about
keepEdgesInBackground
andkeepEdgesInForeground
.Notes:
Suggestion: if implementing the changes proposed here, we should recreate most of the screenshots and re-configure thresholds. This also applies for any implementation removing the orthogonal segments. Orthogonal segments slightly moved the edges which is no longer the case.
Initial implementation is not supporting collapsed elements
There is an impact of the implementation on the example collapsing/expanding the pools
Notice that is not an officially supported feature, it is just used in example. So we could decide to skip fixing the problem.
BPMN diagram of a non regression visual test to review
The diagram
with.outside.flows
used in fit test has non orthogonal segments and a terminal waypoints inside a shape (confirmed with the diagram xml content and display with bpmn-js).I don't know if we wan to keep this: it may be interesting if we want to test the effect of the zoom/fit on segments and terminal waypoints computation. In this case, we may also add a terminal waypoint outside a shape.
If we keep it, snapshot changes will be required if we manage to fix such waypoints.