GoDiagram 11.0 release candidate
GoDiagram 11.0.0-rc1 is available on NuGet for WinForms, WPF and Avalonia. Barring problems found during the RC, this is the API that 11.0 will ship with, so now is the best time to try it with your app and tell us what breaks.
dotnet add package Northwoods.GoDiagram.WinForms --version 11.0.0-rc1
dotnet add package Northwoods.GoDiagram.Wpf --version 11.0.0-rc1
dotnet add package Northwoods.GoDiagram.Avalonia --version 11.0.0-rc1
The 11.0 documentation, samples and installers are at https://next.godiagram.com.
Upgrading from 10.x
11.0 is a major release, and it’s the first time we could tidy up the API, so some code written for 10.x needs changes. Most of them are compile errors with a one-line fix. The new Upgrading to 11.0 page walks through it in order:
- project and package changes;
- the replacement for each changed API;
- behavior that changed without a compile error;
- saved model JSON, which 11.0 still reads from 10.x.
The change log lists every breaking change, grouped by kind.
What’s new since the alpha
Target frameworks. The WinForms and WPF packages target plain net10.0-windows, the default for a new project, so they install into a project created with dotnet new without changing its target framework. WinForms also still supports .NET Framework 4.7.2. Avalonia targets net10.0 and Avalonia 12.
Changed defaults. Some defaults changed, so existing diagrams may look or behave differently:
LayeredDigraphLayout.AlignOptionnow defaults toLayeredDigraphAlign.All, so most layered layouts look different.- Copied node and link data gets new keys, unless
Model.CopiesKeyis set. Brush.LightenandDarkenuse the Oklch color space.- The predefined buttons and figures have a refreshed look.
The Upgrading page shows how to restore the old behavior where you need it.
A tidier API.
- Durations are
TimeSpanvalues instead of milliseconds. - Whole numbers are
intinstead ofdouble. - Several enumerations were renamed, for example
Wrap→TextWrapandOrientation→SegmentOrientation. - Methods such as
Diagram.Addreturn their object, so calls can be chained. - Bad arguments throw
ArgumentExceptionand its subclasses, naming the parameter.
Hardware rendering. The alpha’s static DiagramControl.UseHardwareRendering is replaced by DiagramControl.RenderMode (per control), DiagramControl.DefaultRenderMode and DiagramControl.ActualRenderMode. A control falls back to software rendering if OpenGL isn’t available.
SVG images. The packages no longer depend on an SVG library. To show .svg pictures, add the SvgPictures extension and call SvgPictures.Enable() at startup.
Other changes:
- Model JSON follows System.Text.Json’s conventions.
- Bindings and
Model.Setconvert values using the invariant culture. - Memory leaks were fixed in the WPF and Avalonia controls.
- Many bug fixes.
Installers. If you installed an 11.0 alpha demo, the RC installer replaces it.