Print SynthDef list using SynthDescLib

The following code chunks print the full list of the synth defitions (SynthDef) that are loaded in the server. A Synthdef is the client side representation of a synth on the server-side.

SynthDef library


// print all the SynthDefs
(
SynthDescLib.global.synthDescs.associationsDo { |assoc|
	var name = assoc.key, code = assoc.value.def.func.def.sourceCode;
	code.notNil.if {
		"".postln;
		name.post; ": ".postln;
		code.postln;
	};
};
"";
)

(
SynthDescLib.global.synthDescs.do { |desc|
	if(desc.def.notNil) {
		"\nSynthDef %\n".postf(desc.name.asCompileString);
		desc.def.func.postcs;
	};
};
""  // this prevents the synthDescs collection from posting
)