Table of Contents

Class EdgeEffectsManager

Namespace
FlowGraph.Avalonia.Animation
Assembly
FlowGraph.Avalonia.dll

Manages automatic edge effects based on EdgeStyle settings.

public class EdgeEffectsManager : IDisposable
Inheritance
EdgeEffectsManager
Implements
Inherited Members

Remarks

This manager handles effects beyond simple flow animation: - Rainbow color cycling - Pulsing opacity/glow effects

Works in conjunction with EdgeFlowAnimationManager which handles dash offset animations.

Constructors

EdgeEffectsManager(AnimationManager, Action<Edge, Color>, Action<Edge, double>)

Creates a new EdgeEffectsManager.

public EdgeEffectsManager(AnimationManager animationManager, Action<Edge, Color> updateEdgeColor, Action<Edge, double> updateEdgeOpacity)

Parameters

animationManager AnimationManager

The animation manager to use for running animations.

updateEdgeColor Action<Edge, Color>

Callback to update edge color during rainbow animation.

updateEdgeOpacity Action<Edge, double>

Callback to update edge opacity during pulse animation.

Properties

ActivePulseCount

Gets the number of active pulse animations.

public int ActivePulseCount { get; }

Property Value

int

ActiveRainbowCount

Gets the number of active rainbow animations.

public int ActiveRainbowCount { get; }

Property Value

int

TotalActiveEffects

Gets the total number of active effect animations.

public int TotalActiveEffects { get; }

Property Value

int

Methods

Dispose()

Releases all resources.

public void Dispose()

HasPulseEffect(string)

Checks if an edge has an active pulse effect.

public bool HasPulseEffect(string edgeId)

Parameters

edgeId string

Returns

bool

HasRainbowEffect(string)

Checks if an edge has an active rainbow effect.

public bool HasRainbowEffect(string edgeId)

Parameters

edgeId string

Returns

bool

StartPulseEffect(Edge, EdgeStyle)

Starts a pulsing opacity effect for an edge.

public void StartPulseEffect(Edge edge, EdgeStyle style)

Parameters

edge Edge
style EdgeStyle

StartRainbowEffect(Edge, EdgeStyle)

Starts a rainbow color cycling effect for an edge.

public void StartRainbowEffect(Edge edge, EdgeStyle style)

Parameters

edge Edge
style EdgeStyle

StopAllEffects()

Stops all effects.

public void StopAllEffects()

StopPulseEffect(string)

Stops a pulse effect for an edge.

public void StopPulseEffect(string edgeId)

Parameters

edgeId string

StopRainbowEffect(string)

Stops a rainbow effect for an edge.

public void StopRainbowEffect(string edgeId)

Parameters

edgeId string

SyncEffects(IEnumerable<Edge>)

Synchronizes effects with the current graph state.

public void SyncEffects(IEnumerable<Edge> edges)

Parameters

edges IEnumerable<Edge>

All edges in the graph.