Phase 4: per-widget Inspector tables for Stock/Instrumentation + dispatch

src/props.h gains the generated Phase 4 tables (103 classes, 1008 props)
from tools/gen_phase4_props.py, dispatched on the exact XFrame class name.
The StockChart table is the legacy 8 props plus the candlestick chart's
own Phase 4 props; its up/down defaults are corrected to the widget's
real defaults rgb(0,150,0)/rgb(200,30,30) (the legacy rgb(0,200,0)/
rgb(220,0,0) did not match the widget). src/main.cpp refresh_xframe_props
falls back to the exact class name when xframe_type_key() returns "" so
every Stock*/Inst* class shows its own table, not just common props.
This commit is contained in:
cnmcdee committed 2026-11-30 14:08:12 +00:00
1 parent 05a85ddf8a
commit e68fd2557d
2 files changed
+1345 -3

No files matched your search

+7 -1
View File
@@ -2156,9 +2156,15 @@ static void refresh_xframe_props() {
gtk_widget_set_halign(hdr, GTK_ALIGN_START);
gtk_grid_attach(GTK_GRID(g_props_grid), hdr, 0, row++, 2, 1);
// Phase 4: xframe_type_key() only maps classes with a palette key
// (StockCandlestickChart -> StockChart); every other Stock*/Inst*
// class maps to "", so fall back to the exact class name -- props_for()
// has a per-class Phase 4 table for each of them (same pattern as
// events_for() in events.h).
std::string key = xframe_type_key(m.type);
const std::string& t = key.empty() ? m.type : key;
std::vector<const PropDef*> defs;
for (const PropDef& d : props_for(key)) defs.push_back(&d);
for (const PropDef& d : props_for(t)) defs.push_back(&d);
for (const PropDef& d : common_props()) defs.push_back(&d);
for (const PropDef* d : defs)
add_row(row++, d->name,
+1338 -2
View File
File diff suppressed because it is too large. Load diff