TachyonUI 0.1.0
High-performance UI for building tools.
Loading...
Searching...
No Matches
tachyon::NodeProperty Struct Reference

One row of a node: an optional input socket, a body, and an optional output socket. More...

#include <gui_controls/gui_node_view_types.h>

Public Attributes

std::optional< PropertyEndpoint > input
 Left socket, rendered when has_value(); holds the source output feeding it (one at most).
bool output = false
 Right socket, rendered when true. It drives every input that names it as its source.
std::function< void()> renderBody
 Row body, built between the two sockets; may call any widget (Label, Field, ...).
tachyon::color4f socketColor { 0.9f, 0.9f, 0.9f, 1.0f }
 Socket dot colour, also used for wires leaving this output.
int rowSpan = 1
 Row height in row pitches, for tall bodies (previews, multi-line).
std::string name
 What its sockets' tooltip says: the pin's name, its type (muted, monospace) and its value now, asked for only while the tooltip shows; a wired input also says where its value comes from ("from Noise.Value", the source node's title and this name of its property).
std::string type
std::function< std::string()> value

Detailed Description

One row of a node: an optional input socket, a body, and an optional output socket.

Member Data Documentation

◆ input

std::optional<PropertyEndpoint> tachyon::NodeProperty::input

Left socket, rendered when has_value(); holds the source output feeding it (one at most).

◆ output

bool tachyon::NodeProperty::output = false

Right socket, rendered when true. It drives every input that names it as its source.

◆ renderBody

std::function<void()> tachyon::NodeProperty::renderBody

Row body, built between the two sockets; may call any widget (Label, Field, ...).

◆ socketColor

tachyon::color4f tachyon::NodeProperty::socketColor { 0.9f, 0.9f, 0.9f, 1.0f }

Socket dot colour, also used for wires leaving this output.

◆ rowSpan

int tachyon::NodeProperty::rowSpan = 1

Row height in row pitches, for tall bodies (previews, multi-line).

Whole pitches keep later sockets on the grid.

◆ name

std::string tachyon::NodeProperty::name

What its sockets' tooltip says: the pin's name, its type (muted, monospace) and its value now, asked for only while the tooltip shows; a wired input also says where its value comes from ("from Noise.Value", the source node's title and this name of its property).

No tooltip when the name, type and value are all empty.

◆ type

std::string tachyon::NodeProperty::type

◆ value

std::function<std::string()> tachyon::NodeProperty::value

The documentation for this struct was generated from the following file: