v0.4.0 - Canvas-First Architecture
FlowGraph v0.4.0
⚠️ Breaking Changes
- Canvas-First Architecture - The Graph model now uses a unified
Elementscollection as the primary data source- New API: Use
graph.Elements.Nodesandgraph.Elements.Edgesfor accessing nodes and edges - Deprecated:
graph.Nodesandgraph.Edgesproperties are now marked[Obsolete]but remain functional for backward compatibility - Migration: Replace
graph.Nodeswithgraph.Elements.Nodesandgraph.Edgeswithgraph.Elements.Edgesin your code
- New API: Use
New Features
-
Unified Elements Collection - Single source of truth for all canvas elements
Graph.Elementsproperty provides access to all nodes, edges, and future element typesGraph.Elements.NodesreturnsIEnumerable<Node>for type-safe node accessGraph.Elements.EdgesreturnsIEnumerable<Edge>for type-safe edge access- Enables future extensibility for custom element types (annotations, shapes, etc.)
-
Improved Internal Architecture
- Cleaner separation between the unified elements model and legacy ObservableCollection-based APIs
- Better support for custom renderers and element types
- Simplified coordinate transformations with
RenderElements()API
Migration Guide
Before (v0.3.x):
// Accessing nodes and edges
var nodes = graph.Nodes;
var edges = graph.Edges;
var node = graph.Nodes.FirstOrDefault(n => n.Id == "myNode");After (v0.4.0):
// Use Elements collection for new code
var nodes = graph.Elements.Nodes;
var edges = graph.Elements.Edges;
var node = graph.Elements.Nodes.FirstOrDefault(n => n.Id == "myNode");
// Legacy properties still work but show deprecation warnings
// graph.Nodes and graph.Edges are still available for backward compatibilityNotes
- The deprecated
NodesandEdgesproperties will continue to work and fireCollectionChangedevents - Internal synchronization ensures both APIs stay in sync
- This change prepares the architecture for FlowGraph.Pro features and custom element types
FlowGraph v0.3.6
New Features
-
Custom Edge Renderers - Full extensibility API for custom edge visuals
IEdgeRendererinterface for creating custom edge representations (sequence messages, swimlane flows, etc.)EdgeRendererRegistrywith wildcard pattern matching (e.g.,sequence-*matchessequence-message)EdgeRenderContextprovides source/target nodes, coordinates, theme, and scaleEdgeRenderResultreturns visible path, hit area, markers, labels, and additional visuals- Access via
canvas.EdgeRenderers.Register("my-edge-type", myRenderer)
-
Custom Background Renderers - Extensibility API for custom background layers
IBackgroundRendererinterface for rendering behind graph content (lifelines, swimlane lanes, etc.)BackgroundRendererRegistrysupports multiple concurrent renderers or single-renderer modeBackgroundRenderContextprovides viewport bounds, pan/zoom state, and coordinate transforms- Callbacks for
OnGraphChangedandOnViewportChangedfor efficient updates - Access via
canvas.BackgroundRenderers.Add(myRenderer)orcanvas.BackgroundRenderers.SetSingle(myRenderer)
API Additions
FlowCanvas.EdgeRenderersproperty for registering custom edge typesFlowCanvas.BackgroundRenderersproperty for registering custom backgrounds- Custom renderers are fully integrated into the FlowCanvas render pipeline
FlowGraph v0.3.5
Bug Fixes
- Fixed Node Selection Flakiness - Visual tree hit testing now correctly walks up parent hierarchy to find nodes when clicking on nested child elements (labels, inner grids, etc.)
- Fixed Settings Propagation -
FlowCanvasSettingschanges now properly propagate to all rendering components at runtime:- Added
UpdateSettings()methods toRenderContext,GraphRenderModel,NodeVisualManager,GraphRenderer,ViewportState,GridRenderer,InputStateContext, andDirectGraphRenderer - Settings changes via property binding now trigger full component updates
- Added
- Fixed DirectGraphRenderer Settings Sync - Direct rendering mode now correctly updates its internal
GraphRenderModelwhen settings change, fixing spatial index/hit testing mismatches
Improvements
- Enhanced debug logging for input hit testing diagnostics
FlowGraph v0.3.3
New Features
- Custom Port Renderers - Full extensibility API for custom port visuals
IPortRendererinterface for creating custom port shapes and stylesPortRendererRegistryto map port types to custom renderersDefaultPortRenderermaintains backward compatibility with standard circular portsPortRenderContextprovides port metadata, position, and theme resourcesPortVisualStateenum for hover, connected, and dragging states- Access via
canvas.GraphRenderer.PortRenderers.Register("MyType", myRenderer)
Documentation
- Added Custom Port Renderers section to README features
- New custom-ports.md guide in documentation
FlowGraph v0.3.2
New Features
- LabelInfo for Edge Labels - Enhanced edge label positioning with anchor points and offsets
LabelAnchor.Start- Position label at ~25% along edge (near source)LabelAnchor.Center- Position label at midpoint (default)LabelAnchor.End- Position label at ~75% along edge (near target)- Custom
OffsetXandOffsetYfor fine-tuning label position - Fluent API:
edge.Definition.WithLabelInfo("Label", LabelAnchor.Start, offsetY: -10) - Full JSON serialization support via
LabelInfoDto
Documentation
- Added Edge Label Positioning section to README
- Updated edge-routing.md with LabelInfo documentation
- Added tables documenting LabelAnchor positions and LabelInfo properties
FlowGraph v0.3.1
Documentation Updates
- Comprehensive API Documentation - Updated README and docs to reflect all v0.3.0 API changes
- Definition + State Pattern - Documented new immutable Definition + mutable State architecture
- Batch Loading Guide - Added documentation for
BeginBatchLoad(),EndBatchLoad(), and bulk operations - Performance Guide - New comprehensive guide for optimizing large graphs (virtualization, simplified rendering, direct GPU rendering)
- Enhanced Configuration - Documented all new FlowCanvasSettings properties
- Connection Validation - Updated with new built-in validators and composite patterns
- Events Documentation - Updated event examples with correct property names and new events
- Edge Routing Guide - Updated with new routing API and configuration options
FlowGraph v0.3.0
API Improvements
- Definition + State pattern for cleaner separation of concerns
NodeDefinitionandNodeStatefor immutable/mutable propertiesEdgeDefinitionandEdgeStatefor better edge managementPortDefinitionwith new properties (MaxConnections,IsRequired)BulkObservableCollectionwithAddRange()for batch operations- Improved connection validation with built-in validators
- Enhanced performance settings for large graphs (500+ nodes)
Breaking Changes
- Node and Edge constructors now accept Definition and State parameters (backward-compatible pass-through properties maintained)
ValidationResultrenamed toConnectionValidationResultBoxSelectionModerenamed toSelectionMode- Event property names updated for consistency
FlowGraph v0.2.2
Improvements
- Fixed all compiler warnings (CS8601, CS8602, CS0108, CS0109)
- Improved null safety across codebase
- Renamed internal
FlowDirectionenum toEdgeFlowDirectionto avoid conflict withVisual.FlowDirection
FlowGraph v0.2.0
New Features
- FlowGraph.3D - New package for 3D rendering using OpenGL via Silk.NET
- Data Flow System - Real-time data propagation between connected nodes
- Interactive Node Renderers - Color picker, radio buttons, sliders with state persistence
- 3D Output Node - Demo showcasing data flow with 3D OpenGL visualization
Improvements
- State persistence across visual tree rebuilds (pan/zoom operations)
- Static registry pattern for control reuse
FlowGraph v0.1.0
The first public release of FlowGraph - a node-based graph editor for .NET and Avalonia.
Features
- Pan, zoom, and viewport controls
- Draggable, resizable nodes with custom renderers
- Multiple edge types (Bezier, Straight, Step, SmoothStep)
- Connection validation
- Undo/redo with full command history
- Copy, cut, paste, duplicate
- Node grouping with collapse/expand
- Minimap and controls
- Animations
- Theming support (light/dark)
- JSON serialization
Installation
dotnet add package FlowGraph.AvaloniaDocumentation
Requirements
- .NET 9.0+
- Avalonia 11.2+
MIT License - Prismify LLC