- Notifications
You must be signed in to change notification settings - Fork1.6k
-
I was testing out the graphology-layout-tree mentioned in this discussion#1477 (comment) and for the most part it looks good, but is there a way to prevent the nodes from overlapping as shown in the image here? ![]() Also if I set the itemSizesReference to "positions" as in the storybook all the nodes grow in size and overlap one another so I didn't use that settings (honestly I'm not entirely sure what it's doing since I'm still learning the details of how the rendering works) ![]() I recognize that this isn't necessarily a released feature, but thought I'd ask since my dagre implementation I mentioned in 1477 gets mixed results and this seems much more "native". |
BetaWas this translation helpful?Give feedback.
All reactions
Hi@Rich5,
There are two different issues here, I think:
- The fact that the nodes are not only overlapped, but kind of interlaced, is due to#1427. It will not be solved soon, though, and will be addressed hopefully next year, when we will work onsigma.js v4
- I added a documentation page onhow sigma handles node and edge sizes. This should make it easier for you to better handle sizes in your use-case.
Also, there are some options you can givesome options to thetreeLayout
function:
xGroupsOffset
is the horizontal space between two consecutive depth levels, in pixelsyInGroupOffset
is the vertical space between two consecutive nodes in the same group, in pixelsyGroupsOffset
is the ve…
Replies: 2 comments 4 replies
-
Hi@Rich5, There are two different issues here, I think:
Also, there are some options you can givesome options to the
Combining these options with sigma's setting |
BetaWas this translation helpful?Give feedback.
All reactions
-
Thanks for this! The documentation is very helpful. I guess I missed that before. Playing around with the offset settings and refactoring a bit got me to a good solution. |
BetaWas this translation helpful?Give feedback.
All reactions
-
@jacomyal after more testing I noticed that this also doesn't play well when a customBBox is set. Similar to the initial fitViewportToNodes function noted in#1471 (reply in thread) setting sigma.setCustomBBox(null) before any layout changes seems to work better, but I'm still testing. |
BetaWas this translation helpful?Give feedback.
All reactions
Uh oh!
There was an error while loading.Please reload this page.
-
BetaWas this translation helpful?Give feedback.
All reactions
-
@rahst12 The way I see it, you have different options:
|
BetaWas this translation helpful?Give feedback.
All reactions
👍 1
-
Thanks for the tips, we'll review them! Really excited where all this is headed! |
BetaWas this translation helpful?Give feedback.