Graphviz:如何更改边框颜色

Graphviz:如何更改边框颜色,graph,colors,border,graphviz,Graph,Colors,Border,Graphviz,给定这样一个节点,在白色背景上 "test" [ style="filled,dashed" shape=box color=lightgray label="Hello World" ]; 如何将虚线边框设置为黑色?我找到了一个适合我的解决方案 "test" [ style="filled,dashed" shape=box color=black fillcolor=lightgray label="Hello Wor

给定这样一个节点,在白色背景上

"test" [
    style="filled,dashed"
    shape=box
    color=lightgray
    label="Hello World"
];

如何将虚线边框设置为黑色?

我找到了一个适合我的解决方案

"test" [
    style="filled,dashed"
    shape=box
    color=black
    fillcolor=lightgray
    label="Hello World"
];

这是有误导性的,因为如果未指定
fillcolor
,它似乎会默认为
color

,因此您实际上只需少一行即可获得:

"test" [
    style="filled,dashed"
    shape=box
    fillcolor=lightgray
    label="Hello World"
];

在我的测试中,至少包括一个
fillcolor
,没有
color
默认为黑色边框。

正确。正如文件所说,.@ryandesign的链接已经失效。重要的是,争论的顺序在这里很重要。在
fillcolor
之后指定
color
似乎会覆盖填充颜色(或者至少是与VisJS一起使用时的行为):