-
Notifications
You must be signed in to change notification settings - Fork 6
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
Left -> Right Tree Layout #24
Comments
Thanks for your interest! L2RTreeLayoutDemo The code that maps the layout L2R is this:
If you want to go from right to left, like your example image, change it like this: |
Ah, thanks, I'll give it a try! I've been unable to get any of the demo code to run as the latest Intellij IDEA seems to have serious problems opening the project. For whatever reason, it consistently manages to open the modules in a broken state. |
I use Intellij IDEA for development, so I run the demos with it all the time. To test it everything, I did this: git clone git@github.com:tomnelson/jungrapht-visualization.git After building it, I used File -> Open |
Following those exact steps, I get a project that has no Maven modules and no source directories configured: It's possible to go through and manually set source directories, but notice that it also fails to include any Maven dependencies, and even the "Repair IDE..." option that takes me through a ton of steps to clear indices, reindex, etc, fails in the end. I've not seen this happen with a Maven project before. |
Checking to see if this is still the case on the latest version... ⌛ |
It appears it was a bug with the |
Glad you found a solution. The layout algorithms can take an 'after' function (a Runnable) that runs when they are done. |
I'm still working on this, although I've not been able to tune the code sufficiently to get the sort of output I'm looking for yet. To clarify, I'm working on a patch editor for some audio effects hardware. The signal chain on the hardware is configured as a simple directed graph with a fixed number of possible branches. I wrote a very simple stack-based graph layout algorithm here: This produces output like this: This is fine, but there are occasionally graphs for which the algorithm breaks. Rather than try to exhaustively track down every last edge case, I thought it might be a better idea to look at a general purpose graph layout library. I've not yet been able to get Edit: I do my own edge rendering, so I actually only need the vertex positions. |
If you want to see your graph with many different layouts, I pushed a demo called ShowLayoutsWithIO7MGraph to the master branch. |
Hello!
Is there a way to get tree layouts to be laid out left-to-right instead of top-to-bottom?
Something along the lines of:
https://graphviz.org/Gallery/directed/ninja.svg
The text was updated successfully, but these errors were encountered: