Skip to content

Commit

Permalink
Add spaces around equals sign
Browse files Browse the repository at this point in the history
Find
(?<=[^<>=!+ ])=
replace
 = (space,=)
This had a high occurence of unwanted matches

asdf
  • Loading branch information
mtmccrea committed May 11, 2024
1 parent 764b1bd commit d177b2c
Show file tree
Hide file tree
Showing 27 changed files with 48 additions and 48 deletions.
2 changes: 1 addition & 1 deletion HelpSource/Classes/ArrayedCollection.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ code::
method::normalize
Returns a new Array with the receiver items normalized between strong::min:: and strong::max::.
code::
[1, 2, 3].normalize; //default min = 0, max= 1
[1, 2, 3].normalize; //default min = 0, max = 1
[1, 2, 3].normalize(-20, 10);
::

Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Balance2.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,5 @@ code::

// other examples
{ Balance2.ar(LFSaw.ar(44), Pulse.ar(33), FSinOsc.kr(0.5), 0.1) }.play;
{ var source; source= SinOsc.ar([440, 550]); Balance2.ar(source[0], source[1], LFNoise0.kr(4), 0.3) }.play;
{ var source; source = SinOsc.ar([440, 550]); Balance2.ar(source[0], source[1], LFNoise0.kr(4), 0.3) }.play;
::
6 changes: 3 additions & 3 deletions HelpSource/Classes/BeatTrack2.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ SynthDef(\help_beattrack2_1, { |out, vol = 1.0, beepvol = 1.0, lock = 0, bufnum|
//Look at four features
#trackb, trackh, trackq, tempo, phase, period, groove = BeatTrack2.kr(0, 4, 2.0, 0.02, lock, -2.5);

beep= SinOsc.ar(1000, 0.0, Decay.kr(trackb, 0.1));
beep = SinOsc.ar(1000, 0.0, Decay.kr(trackb, 0.1));
beep = Pan2.ar((vol * in) + (beepvol * beep), 0.0);
Out.ar(out, beep);
}).add;
Expand All @@ -98,7 +98,7 @@ a.free;
code::
//same thing, trying with Onsets UGen raw output
(
a= SynthDef(\help_beattrack2_1, { |out, vol = 1.0, beepvol = 1.0, lock = 0, bufnum|
a = SynthDef(\help_beattrack2_1, { |out, vol = 1.0, beepvol = 1.0, lock = 0, bufnum|
var in, kbus;
var trackb, trackh, trackq, tempo, phase, period, groove;
var bsound, hsound, qsound, beep;
Expand All @@ -116,7 +116,7 @@ a= SynthDef(\help_beattrack2_1, { |out, vol = 1.0, beepvol = 1.0, lock = 0, bufn

feature2 = Onsets.kr(fft, odftype: \complex, rawodf: 1); //two coefficients

kbus= Out.kr(0, [feature1, feature2]);
kbus = Out.kr(0, [feature1, feature2]);

//Look at four features
#trackb, trackh, trackq, tempo, phase, period, groove = BeatTrack2.kr(0, 2, 3.0, 0.02, lock, -2.5);
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/CombC.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ code::

// large delay lines
(
s.options.memSize= 8192*2;
s.options.memSize = 8192*2;
s.reboot;
)
({
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Dictionary.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Creates a Dictionary with an initial capacity for strong::n:: key value mappings
method::newFrom
Creates a new Dictionary from another collection.
code::
d= Dictionary.newFrom([\a, 1, \b, 2, \c, 4]);
d = Dictionary.newFrom([\a, 1, \b, 2, \c, 4]);
::
argument::aCollection
any Object that responds to keysValuesDo (usually a List or an Array).
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/DiskOut.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ code::
x = Synth("bubbles");

// allocate a disk i/o buffer
b= Buffer.alloc(s, 65536, 2);
b = Buffer.alloc(s, 65536, 2);

// create an output file for this buffer, leave it open
b.write("~/diskouttest.wav".standardizePath, "wav", "int16", 0, 0, true);
Expand Down
6 changes: 3 additions & 3 deletions HelpSource/Classes/Done.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -69,10 +69,10 @@ code::
SynthDef("Done-help", { |out, t_trig|
var line, a, b;

line= Line.kr(1, 0, 1);
line = Line.kr(1, 0, 1);

a= SinOsc.ar(440, 0, 0.1*line); //sound fading out
b= WhiteNoise.ar(Done.kr(line)*0.1); //noise starts at end of line
a = SinOsc.ar(440, 0, 0.1*line); //sound fading out
b = WhiteNoise.ar(Done.kr(line)*0.1); //noise starts at end of line

Out.ar(out, Pan2.ar(a+b));
}).add;
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Gendy1.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ code::
(
{
var n;
n =10;
n = 10;

Resonz.ar(
Mix.fill(n, {
Expand Down
4 changes: 2 additions & 2 deletions HelpSource/Classes/Gendy2.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -272,8 +272,8 @@ code::
Mix.fill(n, {
var freq, numcps;

freq= rrand(50, 560.3);
numcps= rrand(2, 20);
freq = rrand(50, 560.3);
numcps = rrand(2, 20);
Pan2.ar(
Gendy2.ar(
6.rand, 6.rand, 1.0.rand, 1.0.rand, freq, freq,
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/History.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,7 @@ History.showLogFile; // current logfile...
// filtering lines, to get subsets of all lines by key and/or searchstring:

// get indices for specific keys
h = History([[0, \me, "a=1+2"], [1, \me, "3+5"], [1.234, \you, "q = q ? ();"], [3, \they, "\"The-story ==== \".postln"]]);
h = History([[0, \me, "a = 1+2"], [1, \me, "3+5"], [1.234, \you, "q = q ? ();"], [3, \they, "\"The-story ==== \".postln"]]);
h.keys;
h.matchKeys(\me);
h.matchKeys(\you);
Expand Down
4 changes: 2 additions & 2 deletions HelpSource/Classes/Image.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -236,14 +236,14 @@ code::
(
i = Image.new(SCDoc.helpSourceDir +/+ "images/Swamp.png");
i.bounds.postln; // getting the dimensions
w =i.plot;
w = i.plot;
)

// changing the size of an image
(
i.scalesWhenResized_(true);
i.setSize(400, (400 / (i.width / i.height)).asInteger);
a =i.plot;
a = i.plot;
)

(
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/InRect.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ code::


//for the Rect, create as left, 'top', width, height;
r= Rect(0, 0, 0, 1)
r = Rect(0, 0, 0, 1)

r.left
r.right
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Integer.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description::
A 32 bit integer. Integer inherits most of its behaviour from its superclass.

note::
A 32 bit signed integer can represent values in the range -2147483648 to 2147483647. Adding up further returns in a wrapped result, so that and 2147483647+1= -2147483648. For a larger range, one can use link::Classes/Float::, which is 64 bit and supports many (but not all) numerical methods that int does.
A 32 bit signed integer can represent values in the range -2147483648 to 2147483647. Adding up further returns in a wrapped result, so that and 2147483647+1 = -2147483648. For a larger range, one can use link::Classes/Float::, which is 64 bit and supports many (but not all) numerical methods that int does.
::


Expand Down
4 changes: 2 additions & 2 deletions HelpSource/Classes/Loudness.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ d = Buffer.read(s, Platform.resourceDir +/+ "sounds/a11wlk01.wav");
// full amp = 100 dB
// -60.dbamp = 0.001 = 1 sone
// -40.dbamp = 0.01 = 4 sone
// -20.dbamp= 0.1 = 16 sone
// 0.dbamp= 1 = 64 sone
// -20.dbamp = 0.1 = 16 sone
// 0.dbamp = 1 = 64 sone
(
{
var in, chain, loudness;
Expand Down
10 changes: 5 additions & 5 deletions HelpSource/Classes/PV_HainsworthFoote.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,8 @@ SynthDef(\fftod, { |out|
(
SynthDef(\fftod, { |out|
var source1, detect;
source1= LFSaw.ar(LFNoise0.kr(1, 90, 400), 0, 0.5);
detect= PV_HainsworthFoote.ar(FFT(LocalBuf(2048), source1), 1.0, 0.0, 0.9, 0.5);
source1 = LFSaw.ar(LFNoise0.kr(1, 90, 400), 0, 0.5);
detect = PV_HainsworthFoote.ar(FFT(LocalBuf(2048), source1), 1.0, 0.0, 0.9, 0.5);
Out.ar(out, Pan2.ar(source1, -1.0) + Pan2.ar(SinOsc.ar(440, 0, Decay.ar(0.1 * detect, 0.1)), 1.0));
}).play(s);
)
Expand All @@ -84,8 +84,8 @@ SynthDef(\fftod, { |out|
(
SynthDef(\fftod, { |out|
var source1, detect;
source1= SoundIn.ar(0);
detect= PV_HainsworthFoote.ar(FFT(LocalBuf(2048), source1), 0.0, 1.0, MouseX.kr(0.0, 1.1), 0.02);
source1 = SoundIn.ar(0);
detect = PV_HainsworthFoote.ar(FFT(LocalBuf(2048), source1), 0.0, 1.0, MouseX.kr(0.0, 1.1), 0.02);
Out.ar(out, Pan2.ar(source1, -1.0) + Pan2.ar(SinOsc.ar(440, 0, Decay.ar(0.1 * detect, 0.1)), 1.0));
}).play(s);
)
Expand All @@ -96,7 +96,7 @@ SynthDef(\fftod, { |out|
SynthDef(\fftod, { |out|
var source1, detect;
source1 = SoundIn.ar(0);
detect= Amplitude.ar(source1) > MouseX.kr(0.0, 1.1);
detect = Amplitude.ar(source1) > MouseX.kr(0.0, 1.1);
Out.ar(out, Pan2.ar(source1, -1.0) + Pan2.ar(SinOsc.ar(440, 0, Decay.ar(0.1 * detect, 0.1)), 1.0));
}).play(s);
)
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/PartConv.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ s.waitForBoot {

bufsize = PartConv.calcBufSize(~fftsize, irbuffer);

// ~numpartitions= PartConv.calcNumPartitions(~fftsize, irbuffer);
// ~numpartitions = PartConv.calcNumPartitions(~fftsize, irbuffer);

~irspectrum = Buffer.alloc(s, bufsize, 1);
~irspectrum.preparePartConv(irbuffer, ~fftsize);
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Pattern.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ Prout({ |inval|

//Pfunc(function) - the function should not have calls to embedInStream, use Prout instead.

Pn(Pbindf(q, \legato, Pfunc({ |inval| if (inval.at(\degree)== 5) { 4 } { 0.2 } }))).play
Pn(Pbindf(q, \legato, Pfunc({ |inval| if (inval.at(\degree) == 5) { 4 } { 0.2 } }))).play



Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Pen.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ example:
code::
(
var w = Window("arcTo", Rect(100, 200, 300, 300)).front;
var r= 15;
var r = 15;
w.drawFunc = { |v|
Pen.fillColor = Color.blue;
Pen.strokeColor = Color.red;
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/Pseed.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ Pdef(\varsawPat,


(
SynthDef(\drum, { |out, dur, t_gate =1, pew = 1, sustain = 1, pan, fed = 0, tun, amp = 1|
SynthDef(\drum, { |out, dur, t_gate = 1, pew = 1, sustain = 1, pan, fed = 0, tun, amp = 1|
var env, freq, sig;
tun = ((tun>0)*tun) + ((tun<1)*3);
freq = (tun*10).midicps;
Expand Down
4 changes: 2 additions & 2 deletions HelpSource/Classes/SCImage.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -206,14 +206,14 @@ code::
(
i = SCImage.new("/Library/Desktop Pictures/Ripples Blue.jpg");
i.bounds.postln; // getting the dimensions
w =i.plot;
w = i.plot;
)

// changing the size of an image
(
i.scalesWhenResized_(true);
i.setSize(400, 400 / (i.width / i.height));
a =i.plot;
a = i.plot;
)
(
a.close; w.close; i.free;
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/ScopeView.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,7 @@ s.waitForBoot({


startButton.action_{
(startButton.value==1).if{
(startButton.value == 1).if{
syn1 = SynthDef("test1", { |bus, bufnum|
var z;
z = In.ar(bus, 2);
Expand Down
8 changes: 4 additions & 4 deletions HelpSource/Classes/SerialPort.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -204,15 +204,15 @@ p = SerialPort(

//read 10bit serial data sent from Arduino's Serial.println
(
r= Routine({
r = Routine({
var byte, str, res;
99999.do{ |i|
if(p.read==10, {
if(p.read == 10, {
str = "";
while({ byte = p.read; byte != 13 }, {
str= str++byte.asAscii;
str = str++byte.asAscii;
});
res= str.asInteger;
res = str.asInteger;
("read value:"+res).postln;
});
};
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/ServerOptions.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ o.numOutputBusChannels = 6; // The next time it boots, this will take effect

// specify a device

o.device ="MOTU Traveler"; // use a specific soundcard
o.device = "MOTU Traveler"; // use a specific soundcard
o.device = nil; // use the system default soundcard

// finally, boot the server
Expand Down
2 changes: 1 addition & 1 deletion HelpSource/Classes/SimpleNumber.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -1588,7 +1588,7 @@ Take a tour of link::Guides/Tour-of-Special-Functions#Exponential Integrals#Expo
method:: expintEn
Returns the exponential integral En of code::z::.

Requires that when code::n == 1::, code::z !=0::.
Requires that when code::n == 1::, code::z != 0::.

method:: expintEi
Returns the exponential integral of code::z::.
Expand Down
4 changes: 2 additions & 2 deletions HelpSource/Classes/Sweep.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ b.free
Sweep can be used as a resettable link::Classes/Phasor:: or link::Classes/Line:: - one that can start, pause, resume and stop. To get a resettable link::Classes/XLine:: behavior change the code::linlin:: to code::linexp:: in the SynthDef below.
code::
(
SynthDef(\lineReset, { |out, start= 0, end= 1, dur= 1, t_trig= 1, run= 1|
SynthDef(\lineReset, { |out, start = 0, end = 1, dur = 1, t_trig = 1, run = 1|
var phasor = Sweep.ar(t_trig, run / dur).linlin(0, 1, start, end, \minmax);
phasor.poll;
Out.ar(out, SinOsc.ar(phasor, 0, 0.2));
Expand All @@ -88,7 +88,7 @@ a.set(\t_trig, 1)
a.free

//shorter duration and downwards...
a= Synth(\lineReset, [\start, 1000, \end, 500, \dur, 0.5])
a = Synth(\lineReset, [\start, 1000, \end, 500, \dur, 0.5])
a.set(\t_trig, 1)
a.set(\run, 0)
a.set(\run, 1)
Expand Down
4 changes: 2 additions & 2 deletions HelpSource/Classes/Tap.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ b = Buffer.alloc(s, s.sampleRate, 1); // enough space for one second of mono aud
SynthDef(\helpTap, { |out, bufnum|
var source, capture;

source= SoundIn.ar(0); // use headphones to avoid feedback
capture= BufWr.ar(source, bufnum, Phasor.ar(0, 1, 0, BufFrames.ir(bufnum), 1));
source = SoundIn.ar(0); // use headphones to avoid feedback
capture = BufWr.ar(source, bufnum, Phasor.ar(0, 1, 0, BufFrames.ir(bufnum), 1));

Out.ar(out, Tap.ar(bufnum, 1, [0.1, 0.9])); // multichannel expansion, so one tap each ear
}).add;
Expand Down
10 changes: 5 additions & 5 deletions HelpSource/Classes/TempoClock.schelp
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ returns:: A Boolean, true if the clock is active or false if the clock has been
method::tempo
Sets or gets the current tempo in beats per second at the current strong::logical time::.
code::
t= TempoClock.new;
t = TempoClock.new;
t.tempo_(2.0); // equivalent to t.tempo = 2.0;
t.tempo;
t.tempo_(72/60) // 72 beats per minute
Expand Down Expand Up @@ -204,7 +204,7 @@ method::play

Plays task (a function) at the next beat, where strong::quant:: is 1 by default. Shortcut for link::#-schedAbs::; see link::#-seconds:: and link::#-nextTimeOnGrid:: for further details on time and quant.
code::
t= TempoClock.default;
t = TempoClock.default;
t.play({ |beats, time, clock| [beats, time, clock].postln });
::

Expand Down Expand Up @@ -279,7 +279,7 @@ Returns a bar as a float relative to link::#-baseBarBeat::.
method::bars2beats
Returns a beat relative to link::#-baseBar::.
code::
t= TempoClock.default;
t = TempoClock.default;
t.bars2beats(t.bar) // downbeat of the current bar
::

Expand All @@ -289,7 +289,7 @@ Returns the logical time to next beat. strong::quant:: is 1 by default, relative
method::nextTimeOnGrid
With default values, returns the next whole beat. strong::quant:: is 1 by default, strong::phase:: is 0. quant is relative to link::#-baseBarBeat::, such that
code::
t= TempoClock.default;
t = TempoClock.default;
t.nextTimeOnGrid(t.beatsPerBar) == t.nextBar // => true
::
Together strong::quant:: and strong::phase:: are useful for finding the next n beat in a bar, e.g. code::nextTimeOnGrid(4, 2):: will return the next 3rd beat of a bar (of 4 beats), whereas code::nextBar-2:: may return an elapsed beat.
Expand All @@ -305,7 +305,7 @@ Returns the current elapsed time. (This method is inherited from link::Classes/C
method::beats2secs
Converts absolute strong::beats:: to absolute strong::seconds::, returning the elapsed time of the clock at the given strong::beats::. Only works for times in the current tempo. If the tempo changes any computed time in future will be wrong.
code::
t= TempoClock.default;
t = TempoClock.default;
t.beats2secs(t.beats) // equivalent to t.seconds
t.beats2secs(0) // how many seconds after startup did beat 0 occur?
::
Expand Down

0 comments on commit d177b2c

Please sign in to comment.