gitmyhub

LazNodeEditor

Pascal ★ 17 updated 13d ago

A full-featured, cross-platform node-based visual editor component for Lazarus IDE (works on Windows and Linux).

A visual node graph editor component for Lazarus and Pascal, add a drag-and-drop node-based interface like Blender's editor to your own desktop app with no external dependencies.

PascalLazarusLCLsetup: moderatecomplexity 3/5

LazNodeEditor is a visual node graph editor component for the Lazarus IDE, which is a free development environment for Pascal. A node graph is the kind of interface you see in tools like Blender or game engines: boxes representing operations connected by lines representing data flow. This component provides that type of interface as a reusable building block you can drop into your own Lazarus application.

The component supports two kinds of connections between nodes: execution flow pins, which control the order operations run, and data pins, which pass values like numbers, text, or booleans between nodes. Nodes can be moved, copied, duplicated, connected, and disconnected through standard mouse interactions. The editor includes snap-to-grid, zoom, pan, and the ability to frame all nodes or fit the view to a selection. An undo and redo system tracks changes, and graphs can be saved and loaded as JSON files.

Building custom node types is the intended use case. You write a class that inherits from the base node type, define its input and output pins in one method, and register it with the editor. From that point it appears in the context menu and can be dragged onto the canvas like any built-in node. An inspector panel can be connected to the editor and automatically displays the properties of whichever node is selected, including editable values for numbers, text, and toggle options.

The component has no external library dependencies and uses only the standard Lazarus LCL toolkit for drawing and interaction. It runs on Windows 10 and 11, as well as Linux with several different graphical backends. Installation is a single file added to a project. The README lists possible uses as visual scripting, shader editors, game logic editors, and automation tools.

Where it fits