Skip to content

feat(proto-app): add Tools menu with dynamic toolbox plugin discovery#55

Merged
pabloinigoblasco merged 3 commits into
developmentfrom
feat/tools-menu
Apr 14, 2026
Merged

feat(proto-app): add Tools menu with dynamic toolbox plugin discovery#55
pabloinigoblasco merged 3 commits into
developmentfrom
feat/tools-menu

Conversation

@pabloinigoblasco
Copy link
Copy Markdown
Collaborator

@pabloinigoblasco pabloinigoblasco commented Apr 14, 2026

Motivation

Without this change, there is no way to open toolbox plugins (FFT, Quaternion, ColorMap, etc.) from the application UI. The ToolboxSession and PluginRegistry infrastructure exists, but nothing in MainWindow wires them to the user interface.

In PJ 3.x, toolbox plugins appear under a "Tools" menu. This PR adds the equivalent to proto_app.

Summary

  • Add a Tools menu to MainWindow via menuBar()->addMenu("&Tools")
  • setupToolboxPanels() iterates registry_.allToolboxes(), creates a ToolboxSession per plugin, and adds a menu action that opens the plugin's dialog via runDialog()
  • After the dialog closes, the chart and series tree are refreshed to reflect any data changes the toolbox produced
  • Toolbox plugins are discovered dynamically at startup — no hardcoded list

Test plan

  • Build pj_proto_app — no compile errors
  • Place a Toolbox .so plugin in the plugin directory — it appears in the Tools menu
  • Click the menu action — the plugin's dialog opens
  • Close the dialog after making changes — chart and series tree refresh
  • No toolbox plugins installed — Tools menu is empty (no crash)

Add a Tools menu to MainWindow that dynamically discovers and lists
all loaded Toolbox plugins. Each plugin appears as a menu action that
opens its dialog via ToolboxSession::runDialog(). After the dialog
closes, the chart and series tree are refreshed.

This is the minimum wiring needed to open toolbox plugins (FFT,
Quaternion, ColorMap, etc.) from the application UI.
toolbox_session.cpp was added by PR #44 but not listed in the
CMakeLists.txt sources, causing undefined reference errors at link time.
@pabloinigoblasco pabloinigoblasco merged commit 6af352a into development Apr 14, 2026
2 checks passed
pabloinigoblasco added a commit that referenced this pull request Apr 15, 2026
Sync from GitHub development:
- PR #45: feat: drag-and-drop support for dialog plugins
- PR #54: fix: persist config on dialog close
- PR #55: feat: Tools menu with toolbox plugin discovery
- PR #56: feat: Python syntax highlighter + runtime language swapping
@pabloinigoblasco pabloinigoblasco deleted the feat/tools-menu branch May 4, 2026 12:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant