Version 1.4.16

Version 1.4.16 is now available.

Changes since 1.4.15:

  • Calculations for Diagram.zoomPoint values fixed when scroll and keyboard-command zooming.
  • Fixed Picture copying, and Picture now reports draw errors in go-debug.
  • Updated BPMN extension templates.
There is now a Search box at samples/index.html, so you can easily search the sample sources.

major new feature in 1.4 is support for animation, mostly layout
animation and animation of expanding trees and subgraphs. You can
disable this animation by setting Diagram.animationManager.isEnabled =
false. It is turned on by default. You can also control its duration, by
setting Diagram.animationManager.duration, in milliseconds.

Major new features:

•Added the AnimationManager class and the Diagram.animationManager property.
•Added the Part.isAnimated property (default is true).
•Added Diagram.highlighteds collection and Diagram.highlight, Diagram.highlightCollection, and Diagram.clearHighlighteds methods.
•Added Part.isHighlighted
property, a standard way of declaring that a Part is highlighted. Use
data binding to change the appearance of your parts, e.g.:

new go.Binding(“stroke”, “isHighlighted”, function (h) { return h ? “red” : “black”; }).ofObject()
•Added TextBlock.overflow
property and TextBlock.OverflowEllipsis and TextBlock.OverflowClip enum
values; clipping is the default behavior when there is not enough room
to draw all of the text.
•Added TreeLayout.layerStyle
property; when set to the new enum value TreeLayout.LayerUniform, all
nodes at the same layer level will be aligned. The default value,
TreeLayout.LayerIndividual, produces the original behavior where each
node only takes up as much depth as it needs, causing its children not
necessarily to be aligned with its siblings’ children.
•Added TreeLayout.commitLayers and LayeredDigraphLayout.commitLayers
overridable methods, for getting information about the size and
position of the “bands” (layout layers) cutting across the diagram,
which is useful when positioning labels or putting rectangular areas
behind each band.
•Added Iterator.any, List.any, Set.any, and Map.any
methods that take a predicate function as an argument and return true
if the predicate is true for at least one item in the collection.
Iterator.all, List.all, Set.all, and Map.all methods that take a
predicate function as an argument and return false if the predicate is
false for at least one item in the collection.
•Added Iterator.each,
List.each, Set.each, and Map.each methods that take a function as an
argument and call it on each item in the collection.

A full list of changes is available in the Change Log.