Reset a widget value with a button

HI - I have on my global panel, a volume slider that I can momentarily raise or lower the main outs of my audio interface. I use 2 hidden sliders, for L and R, and a 3rd one grouped with them to control both. But what I want to do is have a button that I can hit that will reset the sliders back to a specific value (basically a reset to default of 75%). I tried to set the value of a momentary button and group it to the sliders, but it doesnt seem to do what I want. I’m guessing that I’d have to write a script in order to make this happen.


I would use a script (but if other more experienced users know a better way, I’m also interested).
In the Advanced tab of the Widget Properties, set OSC/GPScript Name to MasterSlider resp. ResetButton.

The script would look like:

var ResetButton, MasterSlider : Widget

On WidgetValueChanged(newValue : double) from ResetButton
    SetWidgetValue(MasterSlider, 0.75)

Btw, your name sounds very familiar, also come from the Korg Kronos? (being an (ex?) PCG Tools user?)

There are Script functions to set the widget to its default value (defined in the widget settings).

That might be a good option, as you can adjust this in the UI rather than edit the script.


And not to forget, double-click on a widget sets it to the defined default value.