I want to draw a connection only when the mouse is above a node-port.
How can I archive this?
|
To create connector from port set port constraints as “Draw”. So that when you mouse hover on port , port gets highlighted and able to create connection from port. Please find below code snippet for how to set port constraints.
| |
Is there a way to create a preview of a connector/node when clicking a port so that the user simply clicks a node-port,selects the displaying preview-node and after that the preview disappears again and a real node/connection gets created. |
Currently in diagram we does not have support to show preview of node / connector when click on port. In diagram when you click on port , “Clicked” event gets triggered.By using that event you can add new node / connector in diagram. Please find below code snippet for how to use clicked event.
|