Overlap of Nodes

Hi

The nodes on the diagram can be dragged and placed one on top of the other. Is there a property where this could be disabled.

Thanks

What do you want to happen when the user does that? There are a lot of reasonable alternatives – you need to think carefully about all of them and choose what you want to do. Once you can precisely describe the circumstances and the resulting behaviors, then we can talk about how to implement what you want.

Choices include whether to allow the drag to move nodes to allow overlaps ever or temporarily, whether to allow a drop to succeed or be aborted, and whether a successful drop causes the moved/copied nodes to be shifted or whether the unmoved nodes should be shifted or both.

I need to move it to an empty space… Like given in the example mentioned below…http://www.gojs.net/latest/samples/flowBuilder.html

Tried implementing it … I’m getting an error in the line <span =“hljs-keyword” style=“font-size: 9pt; line-height: normal; color: rgb194, 98, 48; : rgb35, 35, 35;”>function <span =“hljs-title” style=“font-size: 9pt; line-height: normal; color: rgb255, 198, 109; : rgb35, 35, 35;”>shiftNodesToEmptySpaces<span =“hljs-s” style=“font-size: 9pt; line-height: normal; color: rgb208, 208, 255; : rgb35, 35, 35;”>() {<pre -=”" =" hljs " style=“font-size: 9pt; padding: 0.5em; color: rgb230, 225, 220; line-height: normal; : rgb35, 35, 35;”> myDiagram.selection.each(<span =“hljs-”><span =“hljs-keyword” style=“color: rgb194, 98, 48;”>function<span =“hljs-s” style=“color: rgb208, 208, 255;”>(node) {"<pre -="" =" hljs " style=“font-size: 9pt; padding: 0.5em; color: rgb230, 225, 220; line-height: normal; : rgb35, 35, 35;”>Shows it as undefined… checked for myDiagram.selection.count… count is 1