Да, это может быть сделано, едва, но я мог сделать это только с большим количеством возни. Но мне пришлось отбросить ортогональные ребра и использовать прямые линии.
- Каким-то образом создать входной файл, который будет размещать узлы в нужном месте.
- Запустить команду dot / fdp / neato -Tdot> work.dot Это создает расширенный, но действительный входной файл
- Редактировать work.dot , чтобы добавить промежуточные (точечные) узлы и заменить любой исходныйкрая по мере необходимости.
- Запустите команду neato -n -Tsvg / png /..., чтобы получить желаемый результат.
График FAQ говорит о neato -n
В целом, я бы предложил использовать PIC язык. Это ближе к делу.
graph test_chart {
graph [bb="0,0,578,147.6",
nodesep=1,
splines=line
];
node [label="\N",
shape=point
];
{
graph [rank=min];
node [label="",
shape=point
];
A [color=red,
height=0.5,
label=A,
pos="226,129.6",
shape=box,
width=0.75];
}
{
graph [rank=max];
node [shape=box];
B [color=blue,
height=0.5,
label=B,
pos="27,18",
shape=box,
width=0.75];
C [color=blue,
height=0.5,
label=C,
pos="153,18",
shape=box,
width=0.75];
D [color=blue,
height=0.5,
label=D,
pos="299,18",
shape=box,
width=0.75];
E [color=blue,
height=0.5,
label=E,
pos="425,18",
shape=box,
width=0.75];
F [color=blue,
height=0.5,
label=F,
pos="551,18",
shape=box,
width=0.75];
}
edge [color=red]
__Ab [height=0.05,
pos="221,73.8",
width=0.05];
__Bb [height=0.05,
pos="26,73.8",
width=0.05];
__Cb [height=0.05,
pos="143,73.8",
width=0.05];
__Db [height=0.05,
pos="289,73.8",
width=0.05];
__Eb [height=0.05,
pos="415,73.8",
width=0.05];
__Ab -- A
__Bb -- B
__Cb -- C
__Db -- D
__Eb -- E
__Bb -- __Eb
edge [color=blue]
__Ac [height=0.05,
pos="236,52",
width=0.05];
__Cc [height=0.05,
pos="163,52",
width=0.05];
__Dc [height=0.05,
pos="309,52",
width=0.05];
__Ec [height=0.05,
pos="435,52",
width=0.05];
__Fc [height=0.05,
pos="561,52",
width=0.05];
__Ac -- A
__Cc -- C
__Dc -- D
__Ec -- E
__Fc -- F
__Cc -- __Fc
}