Skip to content

Conversation

@sudara
Copy link

@sudara sudara commented Dec 11, 2025

I'm considering using listParameters for documentation / CI so got things up and running again on JUCE 8.

A couple compatibility changes were needed.

std::cout << indent << "Values: ";

if (auto valueStrings = param->getAllValueStrings(); !valueStrings.isEmpty()) {
auto valueStrings = param->getNumSteps() < 50 ? param->getAllValueStrings() : juce::StringArray();
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JUCE now has an assertion in getAllValueStrings which fires if you call it on a float parameter... This is a mildly awkward workaround to determine whether it's "worth" printing out all values (if there are 50 or more, then it won't).

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a comment that explains this? I always like to have non-obvious code like this explained because I'm sure people will wonder this in the future when going through the 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.

2 participants