Problem probably arises because rhythm is initialized only once; this will generate a reference problem causing violin and viola to point to same components. Change command to store input string and then evaluate input string once per score insertion.
This works as expected:
This mangles score output:
Problem probably arises because rhythm is initialized only once; this will generate a reference problem causing violin and viola to point to same components. Change command to store input string and then evaluate input string once per score insertion.