Skip to content

Commit d1ada5f

Browse files
yurchorJamesCrook
authored andcommitted
Fix minor typos
1 parent f420a54 commit d1ada5f

File tree

116 files changed

+195
-195
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

116 files changed

+195
-195
lines changed

src/Audacity.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,7 @@ class wxWindow;
209209

210210
// These macros are used widely, so declared here.
211211
#define QUANTIZED_TIME(time, rate) (floor(((double)(time) * (rate)) + 0.5) / (rate))
212-
// dB - linear amplitude convesions
212+
// dB - linear amplitude conversions
213213
#define DB_TO_LINEAR(x) (pow(10.0, (x) / 20.0))
214214
#define LINEAR_TO_DB(x) (20.0 * log10(x))
215215

src/AudacityApp.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ It handles initialization and termination by subclassing wxApp.
2222

2323
#if 0
2424
// This may be used to debug memory leaks.
25-
// See: Visual Leak Dectector @ http://vld.codeplex.com/
25+
// See: Visual Leak Detector @ http://vld.codeplex.com/
2626
#include <vld.h>
2727
#endif
2828

@@ -1384,7 +1384,7 @@ bool AudacityApp::OnInit()
13841384
std::shared_ptr< wxCmdLineParser > parser{ ParseCommandLine().release() };
13851385
if (!parser)
13861386
{
1387-
// Either user requested help or a parsing error occured
1387+
// Either user requested help or a parsing error occurred
13881388
exit(1);
13891389
}
13901390

@@ -1886,7 +1886,7 @@ bool AudacityApp::CreateSingleInstanceChecker(const wxString &dir)
18861886

18871887
mIPCServ.reset();
18881888

1889-
// Try twice to either become the server or make a connnection to one. If
1889+
// Try twice to either become the server or make a connection to one. If
18901890
// both attempts fail, then there's something wrong that we can't deal with,
18911891
// like insufficient access to create the socket, no memory, etc.
18921892
for (int attempts = 0; attempts < 2; ++attempts)

src/AudioIO.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -2054,7 +2054,7 @@ void AudioIO::PrepareMidiIterator(bool send, double offset)
20542054
// instead of initializing with an Alg_seq, we use begin_seq()
20552055
// below to add ALL Alg_seq's.
20562056
mIterator = std::make_unique<Alg_iterator>(nullptr, false);
2057-
// Iterator not yet intialized, must add each track...
2057+
// Iterator not yet initialized, must add each track...
20582058
for (i = 0; i < nTracks; i++) {
20592059
const auto t = mMidiPlaybackTracks[i].get();
20602060
Alg_seq_ptr seq = &t->GetSeq();
@@ -4389,7 +4389,7 @@ int AudioIoCallback::AudioCallback(const void *inputBuffer, void *outputBuffer,
43894389
#endif
43904390

43914391
// ------ MEMORY ALLOCATIONS -----------------------------------------------
4392-
// tempFloats will be a resusable scratch pad for (possibly format converted)
4392+
// tempFloats will be a reusable scratch pad for (possibly format converted)
43934393
// audio data. One temporary use is for the InputMeter data.
43944394
const auto numPlaybackChannels = mNumPlaybackChannels;
43954395
const auto numCaptureChannels = mNumCaptureChannels;

src/AudioIO.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -700,7 +700,7 @@ class AUDACITY_DLL_API AudioIO final
700700
* audacity actually runs the audio I/O stream at. if there is no suitable
701701
* rate available from the hardware, it returns 0.
702702
* The sampleRate argument gives the desired sample rate (the rate of the
703-
* audio to be handeled, i.e. the currently Project Rate).
703+
* audio to be handled, i.e. the currently Project Rate).
704704
* capturing is true if the stream is capturing one or more audio channels,
705705
* and playing is true if one or more channels are being played. */
706706
double GetBestRate(bool capturing, bool playing, double sampleRate);
@@ -730,7 +730,7 @@ class AUDACITY_DLL_API AudioIO final
730730
* currently in use (for many reasons). The number of Capture and Playback
731731
* channels requested includes an allocation for doing software playthrough
732732
* if necessary. The captureFormat is used for recording only, the playback
733-
* being floating point always. Returns true if the stream opened sucessfully
733+
* being floating point always. Returns true if the stream opened successfully
734734
* and false if it did not. */
735735
bool StartPortAudioStream(const AudioIOStartStreamOptions &options,
736736
unsigned int numPlaybackChannels,

src/AudioIOBase.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -1042,7 +1042,7 @@ wxString AudioIOBase::GetDeviceInfo()
10421042
s << XO("%d - %s\n").Format( i, name );
10431043
}
10441044

1045-
// Determine mixer capabilities - it it doesn't support either
1045+
// Determine mixer capabilities - if it doesn't support either
10461046
// input or output, we emulate them (by multiplying this value
10471047
// by all incoming/outgoing samples)
10481048

src/BatchCommands.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ bool MacroCommands::ReadMacro(const wxString & macro)
187187
if (lines > 0) {
188188
for (int i = 0; i < lines; i++) {
189189

190-
// Find the command name terminator...ingore line if not found
190+
// Find the command name terminator...ignore line if not found
191191
int splitAt = tf[i].Find(wxT(':'));
192192
if (splitAt < 0) {
193193
continue;
@@ -722,7 +722,7 @@ bool MacroCommands::ApplySpecialCommand(
722722
}
723723
// end CLEANSPEECH remnant
724724

725-
/// DoAudacityCommand() takes a PluginID and executes the assocated command.
725+
/// DoAudacityCommand() takes a PluginID and executes the associated command.
726726
///
727727
/// At the moment flags are used only to indicate whether to prompt for
728728
/// parameters

src/Benchmark.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ void BenchmarkDialog::OnRun( wxCommandEvent & WXUNUSED(event))
352352
gPrefs->Write(wxT("/GUI/EditClipCanMove"), false);
353353
gPrefs->Flush();
354354

355-
// Rememebr the old blocksize, so that we can restore it later.
355+
// Remember the old blocksize, so that we can restore it later.
356356
auto oldBlockSize = Sequence::GetMaxDiskBlockSize();
357357
Sequence::SetMaxDiskBlockSize(blockSize * 1024);
358358

src/BlockFile.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,7 @@ size_t BlockFile::CommonReadData(
588588
format == int16Sample &&
589589
sf_subtype_is_integer(info.format)) {
590590
// If both the src and dest formats are integer formats,
591-
// read integers directly from the file, comversions not needed
591+
// read integers directly from the file, conversions not needed
592592
framesRead = SFCall<sf_count_t>(
593593
sf_readf_short, sf.get(), (short *)data, len);
594594
}

src/DeviceManager.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -213,8 +213,8 @@ static void AddSources(int deviceIndex, int rate, std::vector<DeviceSourceMap> *
213213
// If the device is for input, open a stream so we can use portmixer to query
214214
// the number of inputs. We skip this for outputs because there are no 'sources'
215215
// and some platforms (e.g. XP) have the same device for input and output, (while
216-
// Vista/Win7 seperate these into two devices with the same names (but different
217-
// portaudio indecies)
216+
// Vista/Win7 separate these into two devices with the same names (but different
217+
// portaudio indices)
218218
// Also, for mapper devices we don't want to keep any sources, so check for it here
219219
if (isInput && !IsInputDeviceAMapperDevice(info)) {
220220
if (info)
@@ -279,7 +279,7 @@ void DeviceManager::Rescan()
279279
// FIXME: TRAP_ERR PaErrorCode not handled in ReScan()
280280
int nDevices = Pa_GetDeviceCount();
281281

282-
//The heirarchy for devices is Host/device/source.
282+
//The hierarchy for devices is Host/device/source.
283283
//Some newer systems aggregate this.
284284
//So we need to call port mixer for every device to get the sources
285285
for (int i = 0; i < nDevices; i++) {

src/DirManager.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -896,7 +896,7 @@ bool DirManager::AssignFile(wxFileNameWrapper &fileName,
896896
wxDir checkit(dir.GetFullPath());
897897
if(!checkit.IsOpened()) return FALSE;
898898

899-
// this code is only valid if 'value' has no extention; that
899+
// this code is only valid if 'value' has no extension; that
900900
// means, effectively, AssignFile may be called with 'diskcheck'
901901
// set to true only if called from MakeFileBlockName().
902902

@@ -1105,7 +1105,7 @@ wxFileNameWrapper DirManager::MakeBlockFileName()
11051105

11061106
while(1){
11071107

1108-
/* blockfiles are divided up into heirarchical directories.
1108+
/* blockfiles are divided up into hierarchical directories.
11091109
Each toplevel directory is represented by "e" + two unique
11101110
hexadecimal digits, for a total possible number of 256
11111111
toplevels. Each toplevel contains up to 256 subdirs named

src/Envelope.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ void Envelope::CopyRange(const Envelope &orig, size_t begin, size_t end)
283283
}
284284

285285
// Create the final point if it needs interpolated representation
286-
// If the last point of e was exatly at t1, this effectively copies it too.
286+
// If the last point of e was exactly at t1, this effectively copies it too.
287287
if (mTrackLen > 0 && i < len)
288288
AddPointAtEnd( mTrackLen, orig.GetValue(mOffset + mTrackLen));
289289
}

src/EnvelopeEditor.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ bool EnvelopeEditor::HandleDragging(const wxMouseEvent & event, wxRect & r,
316316
return true;
317317
}
318318

319-
// Exit dragging mode and delete dragged point if neccessary.
319+
// Exit dragging mode and delete dragged point if necessary.
320320
bool EnvelopeEditor::HandleMouseButtonUp()
321321
{
322322
mEnvelope.ClearDragPoint();

src/FFmpeg.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -430,12 +430,12 @@ extern "C" {
430430
//
431431
// The FFMPEG_FUNCTION_WITH_RETURN takes 4 arguments:
432432
// 1) The return type <---|
433-
// 2) The function name | Taken from the FFmpeg funciton prototype
433+
// 2) The function name | Taken from the FFmpeg function prototype
434434
// 3) The function arguments <---|
435435
// 4) The argument list to pass to the real function
436436
//
437437
// The FFMPEG_FUNCTION_NO_RETURN takes 3 arguments:
438-
// 1) The function name <---| Taken from the FFmpeg funciton prototype
438+
// 1) The function name <---| Taken from the FFmpeg function prototype
439439
// 2) The function arguments <---|
440440
// 3) The argument list to pass to the real function
441441
//

src/FileFormats.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ wxString sf_header_shortname(int format);
7272
/** @brief Get the most common file extension for the given format
7373
*
7474
* AND the given format with SF_FORMAT_TYPEMASK to get just the container
75-
* format, then retreive the most common extension using SFC_GET_FORMAT_INFO.
75+
* format, then retrieve the most common extension using SFC_GET_FORMAT_INFO.
7676
* @param format the libsndfile format to get the name for (only the container
7777
* part is used) */
7878
wxString sf_header_extension(int format);

src/FreqWindow.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -1012,7 +1012,7 @@ void FrequencyPlotDialog::Recalc()
10121012
// In wxMac, the skipped window MUST be a top level window. I'd originally made it
10131013
// just the mProgress window with the idea of preventing user interaction with the
10141014
// controls while the plot was being recalculated. This doesn't appear to be necessary
1015-
// so just use the the top level window instead.
1015+
// so just use the top level window instead.
10161016
{
10171017
Optional<wxWindowDisabler> blocker;
10181018
if (IsShown())

src/ImageManipulation.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,5 +63,5 @@ std::unique_ptr<wxImage> CreateSysBackground(int width, int height, int offset,
6363
// Pastes one image into another at specified location.
6464
void PasteSubImage( wxImage * pDest, wxImage * pSrc, int x, int y );
6565

66-
// Gets a rectangle from within anothe rimage, INCLUDING the alpha channel
66+
// Gets a rectangle from within another image, INCLUDING the alpha channel
6767
wxImage GetSubImageWithAlpha( const wxImage & Src, const wxRect &rect );

src/Internat.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ extern AUDACITY_DLL_API const wxString& GetCustomSubstitution(const wxString& st
6565
#endif
6666

6767

68-
// The two string arugments will go to the .pot file, as
68+
// The two string arguments will go to the .pot file, as
6969
// msgid sing
7070
// msgid_plural plural
7171
//
@@ -135,7 +135,7 @@ class Internat
135135
*/
136136
static bool SanitiseFilename(wxString &name, const wxString &sub);
137137

138-
/** \brief Remove accelerator charactors from strings
138+
/** \brief Remove accelerator characters from strings
139139
*
140140
* Utility function - takes a translatable string to be used as a menu item,
141141
* for example _("&Splash...\tAlt+S"), and strips all of the menu

src/Lyrics.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ void LyricsPanel::Finish(double finalT)
222222
mHighlightTextCtrl->ShowPosition(0);
223223
}
224224

225-
// Binary-search for the syllable syllable whose char0 <= startChar <= char1.
225+
// Binary-search for the syllable whose char0 <= startChar <= char1.
226226
int LyricsPanel::FindSyllable(long startChar)
227227
{
228228
int i1, i2;

src/MacroMagic.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ For example DEFINE_IMAGE will generate:
2020
2121
- extern int name;
2222
- int name = -1;
23-
- RegisterImage( name, initiialiser, textual_name);
23+
- RegisterImage( name, initialiser, textual_name);
2424
2525
On three different passes. We control which by defining one of
2626
THEME_INITS or THEME_DECLARATIONS or neither of these.

src/MixerBoard.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ class MixerBoard final : public wxWindow, private PrefsListener
203203
void UpdatePrefs() override;
204204

205205
// Add clusters for any tracks we're not yet showing.
206-
// Update pointers for tracks we're aleady showing.
206+
// Update pointers for tracks we're already showing.
207207
void UpdateTrackClusters();
208208

209209
int GetTrackClustersWidth();

src/NoteTrack.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -1069,7 +1069,7 @@ void NoteTrack::ZoomAllNotes()
10691069
}
10701070

10711071
if (!hasNotes) {
1072-
// Semi-arbitary default values:
1072+
// Semi-arbitrary default values:
10731073
minPitch = 48;
10741074
maxPitch = 72;
10751075
}
@@ -1102,7 +1102,7 @@ NoteTrackDisplayData::NoteTrackDisplayData(const NoteTrack* track, const wxRect
11021102
}
11031103
// Effective space, excluding the margins and the lines between some notes
11041104
auto effectiveHeight = r.height - (2 * (mMargin + 1)) - numC - numF;
1105-
// Guarenteed that both the bottom and top notes will be visible
1105+
// Guaranteed that both the bottom and top notes will be visible
11061106
// (assuming that the clamping below does not happen)
11071107
mPitchHeight = effectiveHeight / ((float) span);
11081108

src/NoteTrack.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ class AUDACITY_DLL_API NoteTrack final
138138

139139
/// Zooms out a constant factor (subject to zoom limits)
140140
void ZoomOut(const wxRect &rect, int y) { Zoom(rect, y, 1.0f / ZoomStep, true); }
141-
/// Zooms in a contant factor (subject to zoom limits)
141+
/// Zooms in a constant factor (subject to zoom limits)
142142
void ZoomIn(const wxRect &rect, int y) { Zoom(rect, y, ZoomStep, true); }
143143
/// Zoom the note track around y.
144144
/// If center is true, the result will be centered at y.

src/PitchName.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ TranslatableString PitchName(
5050

5151
// PitchName_Absolute does the same thing as PitchName, but appends
5252
// the octave number, e.g., instead of "C" it will return "C4"
53-
// if the dMIDInote corresonds to middle C, i.e., is 60.
53+
// if the dMIDInote corresponds to middle C, i.e., is 60.
5454
TranslatableString PitchName_Absolute(
5555
const double dMIDInote,
5656
const PitchNameChoice choice = PitchNameChoice::Sharps);

src/PlatformCompatibility.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class PlatformCompatibility
4141
static const FilePath &GetExecutablePath();
4242

4343
//
44-
// Audacity treats the / as a file seperator always for Mac OS,
44+
// Audacity treats the / as a file separator always for Mac OS,
4545
// however /'s are allowed in the filename. In order for /'s to
4646
// work they muse be treated as :'s. To facilitate this, this
4747
// function should be called when opening or saving a file on

src/PluginManager.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ class PluginDescriptor
124124

125125
// Common
126126

127-
// Among other purposes, PluginDescriptor acts as the resouce handle,
127+
// Among other purposes, PluginDescriptor acts as the resource handle,
128128
// or smart pointer, to a resource created in a plugin library, and is responsible
129129
// for a cleanup of this pointer.
130130
ComponentInterface *mInstance;

src/ProjectFileIO.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,7 @@ bool ProjectFileIO::HandleXMLTag(const wxChar *tag, const wxChar **attrs)
334334

335335
if (!bFileVersionFound ||
336336
(fileVersion.length() != 5) || // expecting '1.1.0', for example
337-
// JKC: I commentted out next line. IsGoodInt is not for
337+
// JKC: I commented out next line. IsGoodInt is not for
338338
// checking dotted numbers.
339339
//!XMLValueChecker::IsGoodInt(fileVersion) ||
340340
(fileVersion > wxT(AUDACITY_FILE_FORMAT_VERSION)))
@@ -358,7 +358,7 @@ bool ProjectFileIO::HandleXMLTag(const wxChar *tag, const wxChar **attrs)
358358
// KLUDGE: guess the true 'fileversion' by stripping away any '-beta-Rc' stuff on
359359
// audacityVersion.
360360
// It's fairly safe to do this as it has already been established that the
361-
// puported file version was five chars long.
361+
// supported file version was five chars long.
362362
fileVersion = audacityVersion.Mid(0,5);
363363

364364
bool bIsOld = fileVersion < wxT(AUDACITY_FILE_FORMAT_VERSION);
@@ -459,7 +459,7 @@ void ProjectFileIO::WriteXML(
459459
xmlFile.WriteAttr(wxT("datadir"), dirManager.GetDataFilesDir());
460460

461461
// Note that the code at the start assumes that if mFileName has a value
462-
// then the file has been saved. This is not neccessarily true when
462+
// then the file has been saved. This is not necessarily true when
463463
// autosaving as it gets set by AddImportedTracks (presumably as a proposal).
464464
// I don't think that mDirManager.projName gets set without a save so check that.
465465
if( !IsProjectSaved() )

src/ProjectFileIORegistry.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ class wxString;
1919

2020
namespace ProjectFileIORegistry {
2121

22-
// Type of functions returning objects that intepret a part of the saved XML
22+
// Type of functions returning objects that interpret a part of the saved XML
2323
using TagHandlerFactory =
2424
std::function< XMLTagHandler *( AudacityProject & ) >;
2525

src/ProjectFileManager.cpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,7 @@ bool ProjectFileManager::DoSave (const bool fromSaveAs,
360360
auto &projectFileIO = ProjectFileIO::Get( proj );
361361
const auto &settings = ProjectSettings::Get( proj );
362362

363-
wxASSERT_MSG(!bWantSaveCopy || fromSaveAs, "Copy Project SHOULD only be availabele from SaveAs");
363+
wxASSERT_MSG(!bWantSaveCopy || fromSaveAs, "Copy Project SHOULD only be available from SaveAs");
364364

365365
// Some confirmation dialogs
366366
if (!bWantSaveCopy)
@@ -931,7 +931,7 @@ will be irreversibly overwritten.").Format( fName, fName );
931931
}
932932
else
933933
{
934-
// Overwrite disalowed. The destination project is open in another window.
934+
// Overwrite disallowed. The destination project is open in another window.
935935
AudacityMessageDialog m(
936936
nullptr,
937937
XO("The project will not saved because the selected project is open in another window.\nPlease try again and select an original name."),
@@ -1226,7 +1226,7 @@ void ProjectFileManager::OpenFile(const FilePath &fileNameArg, bool addtohistory
12261226
auto &window = ProjectWindow::Get( project );
12271227

12281228
// On Win32, we may be given a short (DOS-compatible) file name on rare
1229-
// occassions (e.g. stuff like "C:\PROGRA~1\AUDACI~1\PROJEC~1.AUP"). We
1229+
// occasions (e.g. stuff like "C:\PROGRA~1\AUDACI~1\PROJEC~1.AUP"). We
12301230
// convert these to long file name first.
12311231
auto fileName = PlatformCompatibility::ConvertSlashInFileName(
12321232
PlatformCompatibility::GetLongFileName(fileNameArg));
@@ -1444,7 +1444,7 @@ void ProjectFileManager::OpenFile(const FilePath &fileNameArg, bool addtohistory
14441444
// Going through OnClose() may be overkill, but it's safe.
14451445
/*
14461446
// There was an error in the load/check and the user
1447-
// explictly opted to close the project.
1447+
// explicitly opted to close the project.
14481448
mTracks->Clear(true);
14491449
mFileName = wxT("");
14501450
SetProjectTitle();
@@ -1598,7 +1598,7 @@ ProjectFileManager::AddImportedTracks(const FilePath &fileName,
15981598
// See bug #1224
15991599
// The track panel hasn't we been fully created, so the DoZoomFit() will not give
16001600
// expected results due to a window width of zero. Should be safe to yield here to
1601-
// allow the creattion to complete. If this becomes a problem, it "might" be possible
1601+
// allow the creation to complete. If this becomes a problem, it "might" be possible
16021602
// to queue a dummy event to trigger the DoZoomFit().
16031603
wxEventLoopBase::GetActive()->YieldFor(wxEVT_CATEGORY_UI | wxEVT_CATEGORY_USER_INPUT);
16041604
#endif

0 commit comments

Comments
 (0)