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

Self loop nodes #35

Closed
MaximeBouton opened this issue Jul 2, 2019 · 3 comments
Closed

Self loop nodes #35

MaximeBouton opened this issue Jul 2, 2019 · 3 comments

Comments

@MaximeBouton
Copy link
Member

Hello,
Is it possible to draw a node with a self loop? How would one proceed?

I tried the following:

using LightGraphs
g = SimpleDiGraph(2)
add_edge!(g, (2, 1))
add_edge!(g, (1,1))
TikzGraphs.plot(g, node_styles=Dict(1=>"loop below"))

The arrow corresponding to the edge (1,1) seems to be there but is poorly formatted.

image

@mykelk
Copy link
Member

mykelk commented Jul 2, 2019

Very close. It should look like this:
image

@mykelk
Copy link
Member

mykelk commented Jul 2, 2019

We might want to update the docs to illustrate this.

@MaximeBouton
Copy link
Member Author

Thanks! I can submit a PR with this example

@mykelk mykelk closed this as completed Jul 3, 2019
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

No branches or pull requests

2 participants