0
我正在绘制大量节点的大图,这些节点呈现在点dot -Tsvg graph.gv -o graph.svg
中。 为了保持概览我“明确”地定义了我在图的开头使用的所有节点。强制显式创建节点(点,graphviz)
现在我正在寻找一种方法来确保只有那些“显式”定义的节点被使用,并且我没有在边界定义(例如节点名称中的拼写错误)上“隐式”地创建节点。
以下图形的渲染不应起作用,或者在渲染使用“隐式”节点时发出警告。
graph main_graph {
// explicit node definition
node1[style=filled, color=grey];
node2[style=filled, color=grey];
node3[style=filled, color=grey];
subgraph graph1 {
edge [color=red,penwidth=2]
node0 -- node2; //node0 implicitly defined
}
subgraph graph2 {
edge [color="blue",penwidth=2]
node2 -- node3;
node1 -- node3;
}
}
看起来像一个很好的解决方法,我会保持打开周末s检查其他r的想法,然后接受最好的答案。 – RonaldFindling