Don't disable *TRACK* in ";type tool" plugins #3907
Labels
Enhancement Request
Or feature requests. Open-ended requests are better suited for discussions.
macros / scripting
Bugs related to macros and scripts
Your idea
If a Nyquist script / plugin has the header:
;type tool
then the variable TRACK is disabled by Audacity.
Although TRACK only represents a snapshot of the selected audio at the time that the Nyquist script is launched, it can still be very useful. Working around the absence of TRACK can be very complicated.
Problem to be solved
It is often much easier to get information about the initial state of a project by using the properties of TRACK than by other means, but often it is necessary to use complicated "other means" just to work around this restriction.
Example:
To split a selected track exactly in half.
This code would work if TRACK was available in a ;type tool plugin:
but because TRACK is disabled, it's necessary to use two Nyquist scripts plus two additional scripting commands, wrapped up in a macro:
(scroll the code block to see the full code)
Prior art
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: