Table of Contents

Class DirectNodeRenderContext

Namespace
FlowGraph.Avalonia.Rendering.NodeRenderers
Assembly
FlowGraph.Avalonia.dll

Context passed to DrawNode(DrawingContext, Node, DirectNodeRenderContext) with pre-calculated values.

public class DirectNodeRenderContext
Inheritance
DirectNodeRenderContext
Inherited Members

Properties

Background

The background brush for the node.

public required IBrush? Background { get; init; }

Property Value

IBrush

BorderPen

The border pen for the node (changes based on selection state).

public required Pen? BorderPen { get; init; }

Property Value

Pen

IsEditing

Whether this node's label is currently being edited (don't draw the label).

public required bool IsEditing { get; init; }

Property Value

bool

IsSelected

Whether the node is currently selected.

public required bool IsSelected { get; init; }

Property Value

bool

Model

The shared render model for geometry calculations.

public required CanvasRenderModel Model { get; init; }

Property Value

CanvasRenderModel

ScreenBounds

The node bounds in screen coordinates (already transformed by zoom/pan).

public required Rect ScreenBounds { get; init; }

Property Value

Rect

Settings

The canvas settings.

public required FlowCanvasSettings Settings { get; init; }

Property Value

FlowCanvasSettings

TextBrush

The brush for drawing text.

public required IBrush TextBrush { get; init; }

Property Value

IBrush

Theme

The theme resources for additional styling.

public required ThemeResources Theme { get; init; }

Property Value

ThemeResources

Zoom

The current zoom level.

public required double Zoom { get; init; }

Property Value

double