-
Notifications
You must be signed in to change notification settings - Fork 1
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
Cytoscape and Ember #21
Comments
Yeah I have an idea. That persistence after
I can think of a few things for me to be concerned about, but none seem too tricky:
|
I looked at You have nothing to worry about with observers, it's all single execution from a giant for-loop aka Ember's Run-Loop |
The opposite, actually. Cytoscape node and edge objects would be kept statically over the life of the component. They'd be reused for every selection change, mutating their data rather than discarding them. Elements would only be added to the pool if the pool size is too small to service any particular result set. |
Ah, I get it. Pretty clever, actually. However, not easy. |
I'v also noticed that edges in a multiple selection graph can become very cluttered. Any chance we can have a different colour for multiple edges on the same node? |
I'm not sure what the best solution is to the clutter problem. Differently colored edges are simple to implement, but I think I can't think of a way to make it consistently look good. Some options are (in order of complexity):
By design, every member of the selection is connected to each predicate, regardless of selection. The only possible difference is the direction of the edge. So to me it feels like there's actually a lot of redundancy in having an edge between each predicate and selection member. |
I like the idea but rather than hiding all edges not connected to it, highlight/emphasize the edges that are connected? A little more optimal. |
Alright. That's the change I'll make. |
@kdbanman, this is a followup of our earlier discussion.
I've managed to get something working with the container method as follows
I looked into different ways of doing what we want with ember and the ideal/efficient approach would be to initialize cytoscape once on
didInsertElement
and then use array observes for selected, incoming and outgoing as resources are added/removed, since they're all arrays.Peeking into the Cytoscape's API, there doesn't seem a way to completely remove nodes/edges from the graph after adding them. There is a remove method but it keeps old objects in memory which isn't ideal.
I don't think re-initializing the entire graph is an option either.
Unsure where to go from here... feels like a dead end. Ideas?
The text was updated successfully, but these errors were encountered: