Skip to content

Show .nam metadata in a tooltip next to the model - #687

Open
kataque wants to merge 1 commit into
sdatkinson:mainfrom
kataque:model-info-metadata
Open

kataque wants to merge 1 commit into
sdatkinson:mainfrom
kataque:model-info-metadata

Conversation

@kataque

@kataque kataque commented Nov 9, 2026

Copy link
Copy Markdown

Description

Closes #113.

This adds an "i" icon to the right of the model file browser. Hovering over it shows the gear make, gear model and "modeled by" fields from the .nam metadata, one per line, with "(Unknown)" for any field that's missing. The icon is hidden while no model is loaded.

image

Some details:

  • The metadata is read in _StageModel through the get_dsp overload that returns dspData, as in Use model metadata name in browser #658. Each field is type-checked before it's read, since a json::type_error wouldn't be caught by the existing catch (std::runtime_error&).
  • UpdateTooltips() runs whenever the icon is shown or hidden, because macOS only registers tooltip regions for controls that were visible when the window opened. I've only been able to test on Windows.
  • In the .nam files I tried, gear_make and gear_model usually hold the same text, so the name often appears twice. I can merge them into one line if you'd prefer.
  • The icon sits next to the slimmable icon, which moved 22 px to the right to make room. On the left it would knock the model icon out of line with the IR toggle, but that's easy to change.

PR Checklist

  • Did you format your code using format.bash? I ran clang-format on the changed files only, since running it on the whole repo also touched unrelated lines with my clang-format version.
  • Does the VST3 plugin pass all of the unit tests in the VST3PluginTestHost? (Download it as part of the VST3 SDK here.)
    • Windows
    • macOS (I don't have a Mac to test on)
  • Does your PR add, remove, or rename any plugin parameters? No.
  • Does your PR add or remove any graphical assets? No, the icon is drawn in code.

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.

[FEATURE] "Model info" button

1 participant