Vixen
02b45cc4
csharp
public sealed class NodeInspector

The selected node's inline values, as rows beside the canvas.

No guide page documents this yet — the page shows what the code says about itself.

Remarks

Every graph on this framework needs this and none of them should write it twice. A node's numbers live on the graph — in Values, keyed by port name — because that is what survives a save and an undo, so they are not members of an object and InspectorView cannot draw them. What can is the port list the type registry already carries, which is why this needs nothing from the graph it belongs to.

⚠ Only unconnected inputs get a row. A port fed by an edge takes its value from that edge, and an editor showing a number beside it would be showing a value the compiler ignores — which is how somebody comes to spend an afternoon changing a field that does nothing. A connected port keeps its row's place and says where the value comes from.

⚠ Writes go through SetPortValueCommand, so typing a number is one undo entry rather than one per keystroke. NumericInput commits on blur and on Return — see TextInputs — and that commit is the edit.

Fields and properties (5)

  • protected override string TagName

    The element name this type answers to when a caller does not choose one.

  • public NodeGraphView? View

    The view whose selection is shown.

  • public EditorDocument? EditedDocument

    The document edits are recorded against, or for none.

  • public string EmptyMessage

    What the panel says when nothing is selected.

  • public int RowCount

    How many rows are showing.

Methods (3)

  • protected override void OnRemoved()

    Called once, as the element leaves the document.

  • public void Refresh()

    Re-reads the values of the rows that are already there.

  • public void Rebuild()

    Rebuilds the rows for whatever is selected.

Used by (3)

  • PortValueTestsVixen.Editor.NodeGraph.Tests
  • ShaderGraphViewVixen.Editor.AssetEditors
  • VfxGraphViewVixen.Editor.AssetEditors