Skip to content

Implement a dedicated action to open the data browser#3796

Open
rjwills28 wants to merge 2 commits intoControlSystemStudio:masterfrom
rjwills28:open_data_browser_action
Open

Implement a dedicated action to open the data browser#3796
rjwills28 wants to merge 2 commits intoControlSystemStudio:masterfrom
rjwills28:open_data_browser_action

Conversation

@rjwills28
Copy link
Copy Markdown
Contributor

In CS-Studio we used to have an ActionButton, which would run a script to open the data browser and plot specific PVs. This was done using an executeEclipseCommand, e.g.

ScriptUtil.executeEclipseCommand(command_id, ['pvnames', 'XXX:YYY'])

Obviously this is no longer valid in Phoebus.

I am aware that you can launch the data browser from the right click context menu but we would like to be able to be able to do this from a left click action and plot multiple PVs on the same plot. We could not find another suitable way to reproduce this behaviour (e.g. using a command or script).

Instead we thought it would be cleaner to provide a new action to open the data browser. The inputs include a single or list of PVs to plot as well as the timeframe to show. Potentially we could configure other parts of the data browser but this seemed like a good starting point.

We would appreciate any feedback you may have.

Checklist

  • Testing:

    • The feature has automated tests
    • Tests were run
    • If not, explain how you tested your changes
  • Documentation:

    • The feature is documented
    • The documentation is up to date
    • Release notes:
      • Added an entry if the change is breaking or significant
      • Added an entry when adding a new feature

User can specify a single or list of PVs to plot as well as set the
timeframe to display. The default archiver will also be attached to
the PVs.
@georgweiss
Copy link
Copy Markdown
Collaborator

georgweiss commented May 7, 2026

Works as expected.

Since in the data browser users may specify a formula, would it make sense to support it here as well? If yes, then parsing list of PVs would be affected as space chars may be used in formulas.

Simplify construction of URI in action handler to open the data browser.
Rename variables.
Remove copyright note.
Remove unused variables.
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 7, 2026

@kasemir
Copy link
Copy Markdown
Collaborator

kasemir commented May 7, 2026

In your implementation, the OpenDataBrowserActionHandler in display-runtime uses classes from org.csstudio.trends.databrowser3.*.
In principle, it should be possible to open another application from the display without a direct dependency on that application.
For example, the “open file action” can already open any *.plt file using the generic application service.
“open file action” has no direct dependencies to any databrowser or PV table classes, but it can nevertheless open *.plt or *.pvs files via the application service, locating the appropriate application based on the *.plt or *.pvs file association.

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.

3 participants