gpt4 book ai didi

graphviz - 使用 graphviz 和 neato 防止记录重叠

转载 作者:行者123 更新时间:2023-12-03 07:41:17 26 4
gpt4 key购买 nike

我正在构建一个点文件来表示计算机硬件以及与网络交换机和显示器的物理连接。当由点程序处理时,我看起来不错,但我想我真的希望由 neato 处理它,以便在它开始处理时创建一个更“自由形式”的图片。现在,当我用 neato 运行我的大文件时,一切都是重叠的。

我正在尝试找出定义 overlap 属性的语法。以下是我的点文件的子集。

graph g {  
node [shape=record,height=.1];
PC8[label="{{<GigE1>GigE1|<GigE2>GigE2}|{<name>PC8}|{<dvi1>dvi1|<dvi2>dvi2|<dvi3>dvi3|<dvi4>dvi4}}"];
PC9[label="{{<GigE1>GigE1|<GigE2>GigE2}|{<name>PC9}|{<dvi1>dvi1|<dvi2>dvi2|<dvi3>dvi3|<dvi4>dvi4}}"];
C1[label = "{{<dvi1>dvi1}|{<name>C1}}"];
C2[label = "{{<dvi1>dvi1}|{<name>C2}}"];
C3[label = "{{<dvi1>dvi1}|{<name>C3}}"];
C4[label = "{{<dvi1>dvi1}|{<name>C4}}"];
D1[label = "{{<dvi1>dvi1}|{<name>D1}}"];
D2[label = "{{<dvi1>dvi1}|{<name>D2}}"];
"PC8":dvi1 -- "C1":dvi1;
"PC8":dvi2 -- "C2":dvi1;
"PC8":dvi3 -- "C3":dvi1;
"PC8":dvi4 -- "C4":dvi1;
"PC9":dvi1 -- "D1":dvi1;
"PC9":dvi2 -- "D2":dvi1;
}

最佳答案

Well, as with most questions...soon after I posted the I figured out the answer. I needed to add graph [overlap=false]; at the top of the file.

这样做:

graph g {
overlap = false;

node [shape=record,height=.1];
/* ... */
}

关于graphviz - 使用 graphviz 和 neato 防止记录重叠,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1039785/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com