Skip to content
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

Add support for manual ranking #271

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

anyazz
Copy link

@anyazz anyazz commented Jun 28, 2019

This adds an option for g.graph().ranker to be a manually specified ranking function and makes rank a node attribute. Would solve issues like #243 and allow temporary fixes for issues like #150.

@anyazz anyazz marked this pull request as ready for review June 28, 2019 10:06
@wulucxy
Copy link

wulucxy commented Jul 10, 2019

@anyazz hi,do you have any example?I am still have problem with rank field

@vniekecc
Copy link

vniekecc commented Aug 5, 2019

Can this please be merged with dagre-d3? I require this function...

@Murr2016
Copy link

Dear @anyazz
I made a distribuition from your repository »manual-ranking». Unfortunately my browser gives me an error message in my console, saying: layers[node.rank] is undefined. I tried to adjust the cytoscape-dagre.js file, adding rank to the definition of the node-object. This helps not. Do you have any Idea, what to do? Or how to use your addition, either with cytoscape or d3.

I would really be ver happy, if it was possible to give ranks to nodes! Thanks!

@tushevskyi
Copy link

tushevskyi commented Sep 10, 2019

@anyazz hello, as there is no merge for this functionality I manually added changes to the library and ranking start working but edges betwine nodes are break.
I got these errors
And my graph looks as follow (graph)

Is this any solution to fix the links between edges?

@tushevskyi
Copy link

tushevskyi commented Sep 11, 2019

@anyazz hello, again. Is it possible to contact you somehow?

@tolomea
Copy link

tolomea commented Sep 30, 2019

@lutzroeder @anyazz What needs to be done to advance this to a point where it can be merged?

@marionleborgne
Copy link

@lutzroeder not sure if you are the maintainer of dagre, but since you seem to be making most recent commits in dagre-d3, do you think this can be merged and contributed to dagre-d3? I'm looking into adding rank support. Thanks!

@richardwestenra
Copy link

@lutzroeder @anyazz Hey is there any progress on this PR? It would solve a major layout issue for me, and apparently for the author of #289 as well.

@magicDev224
Copy link

@anyazz ranking is not working.
If you have progress please leave me message

@EmilStenstrom
Copy link

Support for syncing the rank of some elements is the only thing stopping dagre for being great for family trees. You want relations between parters to be horizontal and between parent/child to be vertical. Setting the same rank on partners fixes this. Currently the rank attribute on nodes seems to be ignored by dagre.

@el3ctrician
Copy link

Hello Guys, what can i do to get this branch merged ? what are the current issues that needs fixing? i really need this feature and i have some spare time so i might be able to help getting it shipped ...

@EmilStenstrom
Copy link

@el3ctrician I've tried running this branch locally, and it doesn't seem to do anything. So I'm not sure what can be done.

@burner986
Copy link

@anyazz hello, as there is no merge for this functionality I manually added changes to the library and ranking start working but edges betwine nodes are break.
I got these errors
And my graph looks as follow (graph)

Is this any solution to fix the links between edges?

So I also used this fix and came across the same problem you are describing and apparently it's not a problem with the manual ranks but with drawing edges between nodes of the same rank because that seems to not be possible at all. If you try the interactive demo they offer in their wiki then you can also see that whenever you try to draw an edge between nodes of the same rank then one of the nodes will drop/increase in rank automatically. Since with this change the rank is manually set then it will crash and you'll get the error you are seeing

@pbrzosko
Copy link

Hi, do you have any idea whether this can be merged? I need this functionality as well, and I do not need lines between the same rank nodes, so I should be not affected with the bug you mentioned earlier.
What is preventing from merging this change?

@emilianionascu
Copy link

Hey, I'm just adding another comment with "I would love to have this available". Is there anything we can do to help?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet