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

links between object misaligned and straight #971

Open
maximegy opened this issue Feb 16, 2024 · 2 comments
Open

links between object misaligned and straight #971

maximegy opened this issue Feb 16, 2024 · 2 comments

Comments

@maximegy
Copy link

Hello,
I have a fresh install of this tool in mac OS with brew for graphviz.
I try to generate diagrams but I encounter a problem in the interconnection of objects.

Indeed, the links are straight and misaligned instead of making right angles as I saw in the example diagrams.

image

This is the code :

from diagrams import Diagram, Edge, Cluster
from diagrams.custom import Custom

with Diagram("", show=False, direction="LR", filename="schema_archi"):
    internet = Custom("Internet", "SVG/cloud-public.svg")
    
    with Cluster("On Site"):
        CPE1 = Custom("router1", "SVG/routeur1.svg")
        CPE2 = Custom("router2", "SVG/routeur1.svg")
        switch = Custom("Switch", "SVG/SWICH.svg")
        on_site = [CPE1,
                   CPE2] - Edge(style="") - switch

    with Cluster("Backbone"):
        as30781 = Custom("Backbone", "SVG/routeur1.svg")
        ER1 = Custom("edge router 1", "SVG/routeur1.svg")
        ER2 = Custom("edge router 2", "SVG/routeur1.svg")
        routeur = Custom("Routeur", "SVG/routeur1.svg")
        backbone = routeur << as30781 >> [ER1,
                                        ER2]
    
    internet - routeur
    ER1 - CPE1
    ER2 - CPE2

Thanks a lot for your help.

@maximegy
Copy link
Author

I fix the problem with use of "splines":"spline" and I have direct link. When I use "splines":"ortho" I habe the same problem as described.

@maximegy
Copy link
Author

maximegy commented Feb 16, 2024

I have another problem whe i want to add a vertical line between "cpe1" and "cpe2", Vertical align of these nodes goes away :
Capture d’écran 2024-02-17 à 00 12 37
do you have an idea for keep vertical align of those and add line between them ?

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

1 participant