Attribute mclimit
Scandinav21 opened this issue · comments
Hello.
How can I use attribute mclimit for dot graph https://www.graphviz.org/docs/attrs/mclimit/ ?
Didn't find any references :(
Thank you!
Hello!
It seems I didn't expose this attribute as a property, but I'll do that when I find some time soon and will let you know. Thanks for reporting this!
For now, you can just do it this way:
graph.Attributes.Collection.SetCustom(DotAttributeKeys.McLimit, "1.0");
By the way, I'm very curious of an example how this setting impacts the output graph. Could you share your example graph with this attribute set so that I can see how the visualization differs with and without it? I haven't used it so far. Will be grateful.
Cheers!
Hi!
Thank you for the tip!
As I figured out this attribute really didn't bring any changes.
I supposed than this parameter will reduce edge crossing but unfortunately not.
I have one more question about TBbalance attribute https://www.graphviz.org/docs/attrs/TBbalance/.
I couldn't use this like mclimit, can you help with this point?
@Scandinav21, the attribute might have been added after I released the library, so it's not included in the consts yet. But since the consts are just strings, you can pass TBbalance
to the metod directly:
graph.Attributes.Collection.SetCustom("TBbalance", "max");
@mariusz-schimke Thanks a lot and thank you for quick reply!
Cheers!
@Scandinav21, I just released a new version updated to the new attributes that appeared in Graphviz documentation since the last time I made a similar sync a longer while ago. Now you can access the attributes, that you referred to, by properties:
- mclimit:
graph.Layout.EdgeCrossingMinimizationScale = 1.0;
- TBbalance:
graph.Layout.FloatingNodeRank = DotRank.Max;