Set different TreeLayout.angle for each node?

How set different TreeLayout.angle for each node?

You’ll need to override TreeLayout.assignTreeVertexValues.

First, a general discussion about defining extensions to GoJS classes: Introduction to Extensions (the second section, about Layouts).

So define your CustomTreeLayout class:

[code] function CustomTreeLayout() {
go.TreeLayout.call(this);
}
go.Diagram.inherit(CustomTreeLayout, go.TreeLayout);

CustomTreeLayout.prototype.assignTreeVertexValues = function(v) {
var node = v.node;
// maybe look at node.data properties to decide
// what TreeVertex properties to set on V
. . .
};[/code]
In your initialization of your Diagram.layout (or Group.layout), use “CustomTreeLayout” instead of “go.TreeLayout”.

Thank you Walter!