Diagramming for WinForms 7.0 Beta

We have released the new FlowChart.NET for public beta testing a few weeks ago. Diagramming for WinForms V7.0, as its the official name, offers some appealing new features. The most eye-catching is certainly the ability to animate nodes or the entire diagram.


Nodes can be animated in a variety of ways.

In terms of appearance, you can animate the stroke, fill or opacity of the node. Sample code how to do it follows:

    new FillColorAnimation(
        new AnimationOptions
            FromValue = Color.Pink,
            ToValue = Color.Orange,
            Duration = 700,
            Repeat = true,
            RepeatCount = 5,
            Reverse = true,

        })); ;

Another option is to animate nodes in terms of behaviour: you can make them bounce, shake, pulse or move along a predefined path. All animations are members of the MindFusion.Diagramming.Animations class namespace. They take as a parameter an instance of the MindFUsion.ANimations.AnimationOptions class. The property of the class are universal and can be applied to any type of Animation. For example, the FromValue or the ToValue properties are objects, which are assigned according to the animation type – Color, number etc. Do not forget the Repeat and RepeatCount properties, which allow you to make your animations more spectacular by performing them multiple times.

Below is a sample code how you apply a BounceAnimation:

    new BounceAnimation(
        new AnimationOptions
            FromValue = 0,
            ToValue = -5,
            Duration = 222,
            Repeat = true,
            RepeatCount = 4,
            Reverse = true,
            AnimationType = AnimationType.BackBow

Besides animations applied on a single Node, you can apply Animation on the whole diagram. The animation is applied on the DiagramView or one of the classes that derive from it: PagedDiagramView, DiagramView3D etc. The animations supported are:

  • ScrollAnimation
  • ZoomAnimation

As with the animations for nodes, here you can specify the options with the AnimationOptions class. Note the Reverse and Repeat properties. Reverse exchanges the From/ToValue so that the animation can go backwards. This is especially useful when the RepeatCount is an equal number. This way you can make the node/diagram revert to its original looks.

Below is a sample code for a ZoomAnimation that expands and contracts the diagram 2 times:

 new ZoomAnimation(
     new AnimationOptions
         FromValue = 100,
         ToValue = 80,
         AnimationType = AnimationType.Circular,
         EasingType = EasingType.EaseInOut,
         Repeat = true,
         RepeatCount = 4,
         Reverse = true

Diagram Tabs

Another great new feature in FlowChart.NET 7.0 is the PagedDiagramView. The new view splits the diagram into multiple pages. Note that this is different from the existing TabbedView, where each tab was hosting a separate diagram. The PagedDiagramView supports interactive addition/removal of diagram pages. There are also properties for hiding the buttons, navigation through the pages and more.

We have prepared a sample project that uses the beta version libraries for .NET 6.0 and demonstrates the animations, both for nodes and diagram, as well as the DIagramPagedView. You can download the sample projects from this link:

A Demo for Animations & DiagramPagedView in FlowChart.NET 7.0

Multi-touch Support

The new Diagramming library for WinForms can handle Windows touch massages and implements multi-touch gestures.

You have various properties to channel the action that follows a touch gesture:

  • MultiTouchZoom enables the view to be zoomed or panned.
  • MultiTouchModify allows diagram nodes to be moved, rotated or scaled using two-touch pinch or flick gestures.
  • MultiTouchDraw allows or prevents the user from drawing multiple items simultaneously.

The properties are independent from each other and enabling/disabling various combinations of them yields different results. You can read more details at the release announcement page at the MindFusion discussion board.

Async Serialization & Offscreen Printing

The Diagramming API now contains various async methods that allow the diagram to be serialized asynchronously. The new methods create a copy of the diagram and process it in a worker thread. Note that custom Item classes must implement Clone method or Copy constructor in order to make full use of asynchronous serialization. The asynch Save and Load methods are implementd for Json, Xml and binary files. They are called SaveToFile/Xml/JsonFileAsync. Each async Save method has a respective Load counterpart.

Offscreen printing allows diagrams to printed without showing them on a view or even without being opened altogether. The new classes are DiagramPrinter and DiagramDocumentPrinter. They allow you to print the Diagram assigned to the Diagram property of the view or the DiagramDocument assigned to the Document property of the view.

And More…

The beta release surely contains a few bug fixes and several minor properties and improvements. The full list is uploaded at the news page on the forum.

You are welcome to try the beta release from the link below:

Diagramming for WinForms 7.0 Beta

Details about the new features, API members and changes are described on the news post about FlowChart.NET 7.0 Beta at the MindFusion forums. You can also use the FlowChart.NET section on the forum to post your questions about technical support and feature inquiries.