Hi,
Could you please tall me How to produce this simple graph with plantuml ?
digraph G{ nodesep = 0.25 layout=dot a [shape=rectangle width=5 ] b [shape=rectangle width=2] c [shape=rectangle width=5] d [shape=rectangle width=12.5 constraint=false] b-> d [style="invis"] }
digraph G{
nodesep = 0.25
layout=dot
a [shape=rectangle width=5 ]
b [shape=rectangle width=2]
c [shape=rectangle width=5]
d [shape=rectangle width=12.5 constraint=false]
b-> d [style="invis"]
}
https://edotor.net/?engine=osage#digraph%20G%7B%0A%20%20%20%20%20nodesep%20%3D%200.25%0A%20%20%20%20%20layout%3Ddot%20%20%20%20%20%0A%0A%20%20%20%20%20a%20%5Bshape%3Drectangle%20width%3D5%20%5D%0A%20%20%20%20%20b%20%5Bshape%3Drectangle%20width%3D2%5D%0A%20%20%20%20%20c%20%5Bshape%3Drectangle%20width%3D5%5D%20%20%0A%20%20%20%20%20d%20%5Bshape%3Drectangle%20width%3D12.5%20constraint%3Dfalse%5D%20%20%20%20%20%0A%20%20%20%20%20b-%3E%20d%20%5Bstyle%3D%22invis%22%5D%20%20%20%0A%0A%7D
(--------)
The simple way:
The purpose of this post was to give a simple dot graph, which is hard to achieve with plantuml ( I would love to be wrong here ! ) to highlight the difficulties to have so some sort of deterministic layout. ( determinist layout seems to be a difficult topic in some cases)
Anyway, a better way of asking the question could have been :
"How to produce this layout with class diagram ?"
Meaning changing the rectangle just with "class" for example...
That's why I posted also on the forum this question
What is the mapping between Plantuml diagrams and Graphiz Layout (dot, neato, circo...) ?
In Graphviz, layout engines express the different types of projection.
For example, the nop (nop1) nop2 flag in graphviz can be used when we explicitly give positions.
But as far as I know, in Plantuml we have these controls to play with the layout
@startumldigraph foo { PlantUML -> Dot [label=use];}@enduml
@startumlclass adigraph foo { PlantUML -> Dot [label=use];}@enduml
@ The-Lu
Do you have an example of diagram that combines plantuml and dot ?
For example a "class" or an "interface" that points to a graphviz node ?
I am not able to find the right syntax.
Thanks
Hello K.,
Thanks for your precisions.
Here is a minimal example:
@startuml class a label l [ {{ digraph foo { PlantUML -> Dot [label=use]; } }} ] @enduml
But the 2 are independent, and cannot be connected.
If that can help,Regards.