Comments (4)
If you are more familiar with Graphviz attribute names, you can also see the mapping file in this repository. You can look for an attribute name to learn by which programmatic property it is exposed on specific graph elements. In your case this would be:
"fontcolor": [ "Font.Color: DotColor [Graph, Cluster, Node, Edge]" ]
from gigraph.
Thanks a lot. How did I miss that? lol
from gigraph.
Figured it out myself:
node.Attributes.Collection.Set("fontcolor", myColor);
from gigraph.
Glad you wrote! :) Your final solution is correct, but this way you omit the abstraction the library gives you, and provide Graphviz attribute names directly. You can simply do it this way:
node.Font.Color = Color.Red
As long as you only want to adjust the color of the whole label, this is fine. You can generally do the following with the label:
- set font color, font size and font name (for the complete text, not its parts),
- left- or right-justify individual lines of text, or center them.
See here.
When you want to have more granular control on pieces of text, you can use HTML (see here).
from gigraph.
Related Issues (5)
- clusters to have rank as a property HOT 1
- Can u check in your snk HOT 2
- Rank Same with Edges HOT 1
- Attribute mclimit HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gigraph.