feat(gui): material database browser + UserTally editor#12
feat(gui): material database browser + UserTally editor#12dhanavanthesh wants to merge 2 commits into
Conversation
Closes TODO.md lines 46, 102, 103.
Materials: searchable database dialog (59 materials, name + element, filter, composition preview). Auto-selects after add. ojson throughout.
UserTally: replaces // TODO !! with full editor - add/remove/rename/duplicate tallies, 14 bin variables, linspace generator, 6 templates, live summary with traffic-light colors, coordinate system fields.
OptionsModel: notifyDataChanged() replaces setData(idx, QVariant()) across materialsdefview and regionsview - old pattern was silently hitting ojson::parse("") on every array edit. 11 call sites converted.
|
Thank you for your contribution and the effort you put into this PR! Unfortunately, I'll be closing it for two reasons:
Your work on the usertally editor is genuinely appreciated, and I don't want it to go to waste. Please submit it as a standalone PR and I'll be happy to review it properly. Thanks for understanding, and I look forward to your next contribution! |
Closes TODO.md lines 46, 102, 103.
Two config sections that required hand-written JSON now have full GUI editors.
Materials
A database search button is added first in the button row opens a dialog over 59 pre-defined materials loaded via
ojson(noQJsonDocument).materials-screen-recording.mp4
UserTally
// TODO !!atsimulationoptionsview.cpp:74replaced with a fullUserTallyViewwidget.Tally management
_copy,_copy2, ...Bin variable table
[~]- linspace dialog per row: enter min, max, N, live edge preview[×]- removes that variableLive summary
"2D tally: x × E (100 × 50 = 5000 bins)"~40.0 KB/~2.30 MBCoordinate system
Templates
x : 0 to 100 (100 bins)per variableuser_tally-screen-recording.mp4
Also fixed a latent issue in
OptionsModel-setData(idx, QVariant())was silently reachingojson::parse("")on every array edit from the GUI. Replaced withnotifyDataChanged()across all 11 call sites inmaterialsdefviewandregionsview. Empty string guard added inparse_json::set_impl_. Container nodes marked non-editable inflags().New:
materialdatabasedialog.h/.cpp,usertallyview.h/.cpp,database-search.svg,materials_database.json,tally_templates.jsonModified:
materialsdefview,simulationoptionsview,optionsmodel,parse_json.cpp,opentrim.qrc,CMakeLists.txt,TODO.md