In MXGraph, edges can be added using graph.addEdge() but this requires passing 2 vertices as arguments. I want to create an edge which can be randomly placed on the graph, without the need to the vertices, just like in draw.io or graph editor. After googling, mxCell can be used for the same but I am not able to understand the usage. Please Help.
相关问题
- Views base64 encoded blob in HTML with PHP
- Is there a limit to how many levels you can nest i
- Illegal to have multiple roots (start tag in epilo
- How to toggle on Order in ReactJS
- void before promise syntax
Whenever you use mxCells, you need to set TerminalPoints for each of the sides if you are using it as an Edge. After Adding and setting it as an edge you need to insert it into the cells array which has been done by the fireEvent function.