Tims
Tims

Reputation: 641

Graphviz: Distinct colors for xlabel and nodelabel

Is it possible to have distinct font colors for xlabel and node label in Graphviz?

digraph {
    "complete" [xlabel="complete", label="complete", fontcolor=red];
}

Upvotes: 2

Views: 1553

Answers (1)

sroush
sroush

Reputation: 6763

Only way I know of is a bit of a kludge. Use html labels for the label or xlabel:

digraph {
    "complete" [xlabel=<<font color="green">Xcomplete</font>>
        label="complete", fontcolor=red];
}

produces this: enter image description here

Upvotes: 10

Related Questions