NodeFlowConfig class

Reactive configuration class for NodeFlow properties

Constructors

NodeFlowConfig({bool snapToGrid = false, bool snapAnnotationsToGrid = false, double gridSize = 20.0, double portSnapDistance = 10.0, double minZoom = 0.5, double maxZoom = 2.0, bool showMinimap = false, bool isMinimapInteractive = true, MinimapPosition minimapPosition = MinimapPosition.bottomRight, Size minimapSize = const Size(200, 150), bool showAttribution = true})

Properties

gridSize → Observable<double>
Grid size for snapping calculations
final
hashCode int
The hash code for this object.
no setterinherited
isMinimapInteractive → Observable<bool>
Whether the minimap can be interacted with
final
maxZoom → Observable<double>
Maximum allowed zoom level
final
minimapPosition → Observable<MinimapPosition>
Position of the minimap
final
minimapSize → Observable<Size>
Size of the minimap
final
minZoom → Observable<double>
Minimum allowed zoom level
final
portSnapDistance → Observable<double>
Distance threshold for port snapping during connection
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showAttribution bool
Whether to show attribution label
final
showMinimap → Observable<bool>
Whether to show minimap overlay
final
snapAnnotationsToGrid → Observable<bool>
Whether to snap annotation positions to grid
final
snapToGrid → Observable<bool>
Whether to snap node positions to grid
final

Methods

copyWith({bool? snapToGrid, bool? snapAnnotationsToGrid, double? gridSize, double? portSnapDistance, double? minZoom, double? maxZoom, bool? showMinimap, bool? isMinimapInteractive, MinimapPosition? minimapPosition, Size? minimapSize, bool? showAttribution}) NodeFlowConfig
Create a copy with different initial values (for migration purposes) This creates a new config instance with the specified values
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
setMinimapPosition(MinimapPosition position) → void
Set minimap position
setMinimapSize(Size size) → void
Set minimap size
snapAnnotationsToGridIfEnabled(Offset position) Offset
Helper method to snap annotation coordinates to grid if enabled
snapToGridIfEnabled(Offset position) Offset
Helper method to snap coordinates to grid if enabled
toggleAnnotationSnapping() → void
Toggle only annotation snapping
toggleMinimap() → void
Toggle minimap visibility
toggleNodeSnapping() → void
Toggle only node snapping
toggleSnapping() → void
Toggle grid snapping for both nodes and annotations
toString() String
A string representation of this object.
inherited
update({bool? snapToGrid, bool? snapAnnotationsToGrid, double? gridSize, double? portSnapDistance, double? minZoom, double? maxZoom, bool? showMinimap, MinimapPosition? minimapPosition, Size? minimapSize}) → void
Update multiple properties at once

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Properties

defaultConfig NodeFlowConfig
Default configuration factory
no setter