First time here? Check out the FAQ!

Is there a way to script the code which generates Tick Marks labels on a widget?

0 votes

I think this may have been asked before... I want to be able to label widgets dynamically from my Signal Flow scripts, as SSC does in the Index parameter of MultiSample etc.

For example, some code in an encapsulated class could extract marker names or filenames and label a widget accordingly

| names samplesFile |

samplesFile := 'tejadarom-monomarked.aif' asSamplesFile.

names :=
1 to: 14 collect: [ :i |
    samplesFile markers keyAtValue: (samplesFile markers asSortedCollection at: i)  


I wondered if this algorithmic naming is still not possible?

asked May 27, 2016 in Capytalk & Smalltalk by cristian-vogel (Master) (8,370 points)
edited May 27, 2016 by cristian-vogel

1 Answer

0 votes
If you unlock the VCS, select the widget, then from the Options drop-down, select Set tick marks and Labels — you could select code, click edit and use your code snippet in there.  However, there's no way to do for arbitrary lists in an encapsulated class.
answered May 27, 2016 by ssc (Savant) (121,430 points)