wiRedPanda
Logic Circuit Simulator
Loading...
Searching...
No Matches
PropertyDescriptor Struct Reference

Describes one editable property that a GraphicElement exposes in the ElementEditor. More...

#include <PropertyDescriptor.h>

Public Types

enum class  Type {
  Label , Color , Frequency , Delay ,
  Audio , AudioBox , Trigger , TruthTable ,
  Appearance , Volume , WirelessModeSelector
}
 Identifies which property this descriptor represents. More...

Public Attributes

Type type
 Which property this descriptor represents.

Detailed Description

Describes one editable property that a GraphicElement exposes in the ElementEditor.

Each element returns the list of descriptors it supports via GraphicElement::editableProperties(). The ElementEditor uses this list both to decide which UI sections to show (computeCapabilities / applyCapabilitiesToUi) and to dispatch property writes back to the element (apply / applyProperty). Adding a new property type requires only: a new Type enum value, one entry in GraphicElement::editableProperties(), one case in ElementEditor::applyProperty(), and one UI section in applyCapabilitiesToUi(). No other existing code changes.

Definition at line 22 of file PropertyDescriptor.h.

Member Enumeration Documentation

◆ Type

enum class PropertyDescriptor::Type
strong

Identifies which property this descriptor represents.

Enumerator
Label 

User-visible text label.

Color 

Color selection (LEDs, displays).

Frequency 

Clock oscillation frequency in Hz.

Delay 

Phase delay as fraction of the clock period.

Audio 

Audio note selection (buzzer tone).

AudioBox 

AudioBox file selection dialog.

Trigger 

Keyboard trigger shortcut.

TruthTable 

Editable truth table dialog.

Appearance 

Custom pixmap appearance selection.

Volume 

Audio playback volume (AudioBox, Buzzer).

WirelessModeSelector 

Wireless routing mode (None / Tx / Rx) — Node elements only.

Definition at line 24 of file PropertyDescriptor.h.

Member Data Documentation

◆ type

Type PropertyDescriptor::type

Which property this descriptor represents.

Definition at line 38 of file PropertyDescriptor.h.


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