diff --git a/src/AudacityApp.cpp b/src/AudacityApp.cpp index 689c0a79a..bc7c6d18c 100644 --- a/src/AudacityApp.cpp +++ b/src/AudacityApp.cpp @@ -1008,8 +1008,11 @@ bool AudacityApp::OnInit() #endif mLogger=NULL; + /* i18n-hint: We translate the title of the log window, but + * we're not translating its contents, since the contents will be read by + * English speaking engineers */ #ifndef __WXMAC__ - mLogger = new wxLogWindow(NULL, wxT("Audacity Log"), false, false); + mLogger = new wxLogWindow(NULL, _("Audacity Log"), false, false); mLogger->SetActiveTarget(mLogger); mLogger->EnableLogging(true); mLogger->SetLogLevel(wxLOG_Max); @@ -1226,7 +1229,7 @@ bool AudacityApp::OnInit() project->MayStartMonitoring(); #ifdef __WXMAC__ - mLogger = new wxLogWindow(NULL, wxT("Audacity Log"), false, false); + mLogger = new wxLogWindow(NULL, _("Audacity Log"), false, false); mLogger->SetActiveTarget(mLogger); mLogger->EnableLogging(true); mLogger->SetLogLevel(wxLOG_Max); diff --git a/src/DirManager.cpp b/src/DirManager.cpp index 0587e7e4b..e8225b93d 100644 --- a/src/DirManager.cpp +++ b/src/DirManager.cpp @@ -1369,6 +1369,12 @@ int DirManager::ProjectFSCK(const bool bForceError, const bool bAutoRecoverMode) if (bForceError && !bAutoRecoverMode) { + // TODO: Replace with more user friendly error message? + /* i18n-hint: The audacity project file is XML and has 'tags' in it, + rather like html tags some stuff. + This error message is about the tags that hold the sequence information. + The error message is confusing to users in English, and could just say + "Found problems with when checking project file." */ wxString msg = _("Project check read faulty Sequence tags."); const wxChar *buttons[] = {_("Close project immediately with no changes"), diff --git a/src/LabelDialog.cpp b/src/LabelDialog.cpp index f2137003d..1c84de848 100644 --- a/src/LabelDialog.cpp +++ b/src/LabelDialog.cpp @@ -49,17 +49,7 @@ enum Column Col_Max }; -static const wxChar *headers[Col_Max] = -{ - /* i18n-hint: (noun). A track contains waves, audio etc.*/ - _("Track"), - /* i18n-hint: (noun)*/ - _("Label"), - /* i18n-hint: (noun) of a label*/ - _("Start Time"), - /* i18n-hint: (noun) of a label*/ - _("End Time") -}; + class RowData { @@ -146,10 +136,14 @@ LabelDialog::LabelDialog(wxWindow *parent, mGrid->CreateGrid(0, Col_Max); mGrid->SetDefaultCellAlignment(wxALIGN_LEFT, wxALIGN_CENTER); - int i; - for (i = 0; i < Col_Max; i++) { - mGrid->SetColLabelValue(i, headers[i]); - } + /* i18n-hint: (noun). A track contains waves, audio etc.*/ + mGrid->SetColLabelValue(0,_("Track")); + /* i18n-hint: (noun)*/ + mGrid->SetColLabelValue(1,_("Label")); + /* i18n-hint: (noun) of a label*/ + mGrid->SetColLabelValue(2,_("Start Time")); + /* i18n-hint: (noun) of a label*/ + mGrid->SetColLabelValue(3,_("End Time")); // Create and remember editors. No need to delete these as the wxGrid will // do it for us. diff --git a/src/Menus.cpp b/src/Menus.cpp index 3b7c2b19c..6bc124aac 100644 --- a/src/Menus.cpp +++ b/src/Menus.cpp @@ -4074,7 +4074,9 @@ void AudacityProject::OnDisjoinLabels() EditByLabel( &WaveTrack::Disjoin, false ); PushState( - /* i18n-hint: (verb) Audacity has just detached the labeled regions*/ + /* i18n-hint: (verb) Audacity has just detached the labeled regions. + This message appears in history and tells you about something + Audacity has done.*/ _( "Detached labeled regions" ), /* i18n-hint: (verb)*/ _( "Detach Labels" ) ); diff --git a/src/Project.cpp b/src/Project.cpp index 3359d767a..7a1e160e5 100644 --- a/src/Project.cpp +++ b/src/Project.cpp @@ -865,6 +865,9 @@ AudacityProject::AudacityProject(wxWindow * parent, wxWindowID id, mMainPanel = Factory.AddPanel( this, wxPoint( left, top ), wxSize( width, height ) ); pNotebook = Factory.AddNotebook( mMainPanel ); + /* i18n-hint: This is an experiemental feature where the main panel in + Audacity is put on a notebook tab, and this is the name on that tab. + Other tabs in that notebook may have instruments, patch panels etc.*/ pPage = Factory.AddPage( pNotebook, _("Main Mix")); #else // Not using a notebook, so we place the track panel inside another panel, diff --git a/src/Sequence.cpp b/src/Sequence.cpp index 62c929e0e..91f6644ec 100644 --- a/src/Sequence.cpp +++ b/src/Sequence.cpp @@ -1500,6 +1500,12 @@ bool Sequence::Append(samplePtr buffer, sampleFormat format, if (format != mSampleFormat) { temp = NewSamples(mMaxSamples, mSampleFormat); wxASSERT(temp); + // TODO: Make error message clearer? + /* i18n-hint: Error message shown when Audacity was trying to allocate + memory to hold audio, and didn't have enough. 'New Samples' is + the name of the C++ function that failed, for use by a developer, + and should not be translated - though you could say + 'in function "NewSamples()"' to be clearer.*/ if (!temp) { wxMessageBox(_("Memory allocation failed -- NewSamples")); return false; diff --git a/src/Shuttle.cpp b/src/Shuttle.cpp index a0715ffc4..5628e109e 100644 --- a/src/Shuttle.cpp +++ b/src/Shuttle.cpp @@ -70,14 +70,14 @@ preferences. //#include "commands/CommandManager.h" //#include "effects/Effect.h" -const int Enums::NumDbChoices = 14; +const int Enums::NumDbChoices = 13; const wxString Enums::DbChoices[] = {wxT("-20 dB"), wxT("-25 dB"), wxT("-30 dB"), wxT("-35 dB"), wxT("-40 dB"), wxT("-45 dB"), wxT("-50 dB"), wxT("-55 dB"), wxT("-60 dB"), wxT("-65 dB"), wxT("-70 dB"), wxT("-75 dB"), - wxT("-80 dB"), wxT("Off-Skip")}; + wxT("-80 dB")}; const double Enums::Db2Signal[] = // -20dB -25dB -30dB -35dB -40dB -45dB -50dB -55dB -60dB -65dB -70dB -75dB -80dB Off diff --git a/src/TimerRecordDialog.cpp b/src/TimerRecordDialog.cpp index 0cbe53c66..7636037aa 100644 --- a/src/TimerRecordDialog.cpp +++ b/src/TimerRecordDialog.cpp @@ -327,7 +327,7 @@ void TimerRecordDialog::PopulateOrExchange(ShuttleGui& S) S.SetBorder(5); S.StartVerticalLay(true); { - wxString strFormat = wxT("099 h 060 m 060 s"); + wxString strFormat = _("099 h 060 m 060 s"); S.StartStatic(_("Start Date and Time"), true); { m_pDatePickerCtrl_Start = @@ -368,7 +368,7 @@ void TimerRecordDialog::PopulateOrExchange(ShuttleGui& S) S.StartStatic(_("Duration"), true); { - wxString strFormat1 = wxT("099 days 024 h 060 m 060 s"); + wxString strFormat1 = _("099 days 024 h 060 m 060 s"); m_pTimeTextCtrl_Duration = new TimeTextCtrl(this, ID_TIMETEXT_DURATION, strFormat1); m_pTimeTextCtrl_Duration->SetName(_("Duration")); m_pTimeTextCtrl_Duration->SetTimeValue(m_TimeSpan_Duration.GetSeconds().ToDouble()); diff --git a/src/TrackPanelAx.cpp b/src/TrackPanelAx.cpp index be880fc36..307e95792 100644 --- a/src/TrackPanelAx.cpp +++ b/src/TrackPanelAx.cpp @@ -305,15 +305,21 @@ wxAccStatus TrackPanelAx::GetName( int childId, wxString* name ) // LLL: Remove these during "refactor" if( t->GetMute() ) { + /* i18n-hint: This is for screen reader software and indicates that + on this track mute is on.*/ *name->Append( _( " Mute On" ) ); } if( t->GetSolo() ) { + /* i18n-hint: This is for screen reader software and indicates that + on this track solo is on.*/ *name->Append( _( " Solo On" ) ); } if( t->GetSelected() ) { + /* i18n-hint: This is for screen reader software and indicates that + this track is selected.*/ *name->Append( _( " Select On" ) ); } } diff --git a/src/VoiceKey.cpp b/src/VoiceKey.cpp index 27ddf7248..7c32e49eb 100644 --- a/src/VoiceKey.cpp +++ b/src/VoiceKey.cpp @@ -85,6 +85,11 @@ sampleCount VoiceKey::OnForward (WaveTrack & t, sampleCount start, sampleCount l if((mWindowSize) >= len+10){ + /* i18n-hint: Voice key is an experiemental/incomplete feature that + is used to navigate in vocal recordings, to move forwards and + backwards by words. So 'key' is being used in the sense of an index. + This error message means that you've selected too short + a region of audio to be able to use this feature.*/ wxMessageBox(_("Selection is too small to use voice key.")); return start; } diff --git a/src/effects/Equalization.cpp b/src/effects/Equalization.cpp index 71ea3d046..823b413bd 100644 --- a/src/effects/Equalization.cpp +++ b/src/effects/Equalization.cpp @@ -1705,7 +1705,7 @@ void EqualizationDialog::setCurve(wxString curveName) break; if( i == mCurves.GetCount()) { - wxMessageBox( wxT("Requested curve not found, using 'unnamed'"), wxT("Curve not found"), wxOK|wxICON_ERROR ); + wxMessageBox( _("Requested curve not found, using 'unnamed'"), _("Curve not found"), wxOK|wxICON_ERROR ); setCurve((int) mCurves.GetCount()-1); } else diff --git a/src/effects/Leveller.cpp b/src/effects/Leveller.cpp index 7e57d477f..d22d3f80b 100644 --- a/src/effects/Leveller.cpp +++ b/src/effects/Leveller.cpp @@ -43,18 +43,18 @@ EffectLeveller::EffectLeveller() Init(); } -#define NUM_PASSES_CHOICES 6 +#define NUM_PASSES_CHOICES 5 bool EffectLeveller::Init() { - mLevellerNumPasses = gPrefs->Read(wxT("/CsPresets/LevellerNumPasses"), 2L); - if ((mLevellerNumPasses < 0) || (mLevellerNumPasses >= NUM_PASSES_CHOICES)) { // corrupted Prefs? - mLevellerNumPasses = 0; - gPrefs->Write(wxT("/CsPresets/LevellerNumPasses"), 0); + mLevellerNumPasses = gPrefs->Read(wxT("/CsPresets/LevellerNumPasses"), 2L) ; + if ((mLevellerNumPasses <= 0) || (mLevellerNumPasses >= NUM_PASSES_CHOICES)) { // corrupted Prefs? + mLevellerNumPasses = 1; + gPrefs->Write(wxT("/CsPresets/LevellerNumPasses"), 1); } mLevellerDbChoiceIndex = gPrefs->Read(wxT("/CsPresets/LevellerDbChoiceIndex"), 10L); if ((mLevellerDbChoiceIndex < 0) || (mLevellerDbChoiceIndex >= Enums::NumDbChoices)) { // corrupted Prefs? - mLevellerDbChoiceIndex = (Enums::NumDbChoices - 1); //Off-skip + mLevellerDbChoiceIndex = 0; //Least dB gPrefs->Write(wxT("/CsPresets/LevellerDbChoiceIndex"), mLevellerDbChoiceIndex); } mLevellerDbSilenceThreshold = Enums::Db2Signal[mLevellerDbChoiceIndex]; @@ -66,7 +66,7 @@ bool EffectLeveller::Init() bool EffectLeveller::CheckWhetherSkipEffect() { - return ((mLevellerDbChoiceIndex >= (Enums::NumDbChoices - 1)) || (mLevellerNumPasses == 0)); + return mLevellerNumPasses == 0; } void EffectLeveller::End() @@ -116,7 +116,7 @@ bool EffectLeveller::PromptUser() { LevellerDialog dlog(this, mParent); dlog.mLevellerDbChoiceIndex = mLevellerDbChoiceIndex; - dlog.mLevellerNumPasses = mLevellerNumPasses; + dlog.mLevellerNumPassesChoicIndex = mLevellerNumPasses-1; dlog.TransferDataToWindow(); dlog.CentreOnParent(); @@ -126,7 +126,7 @@ bool EffectLeveller::PromptUser() return false; } - mLevellerNumPasses = dlog.mLevellerNumPasses; + mLevellerNumPasses = dlog.mLevellerNumPassesChoicIndex+1; mLevellerDbChoiceIndex = dlog.mLevellerDbChoiceIndex; mLevellerDbSilenceThreshold = Enums::Db2Signal[mLevellerDbChoiceIndex]; gPrefs->Write(wxT("/CsPresets/LevellerDbChoiceIndex"), mLevellerDbChoiceIndex); @@ -192,7 +192,7 @@ LevellerDialog::LevellerDialog(EffectLeveller *effect, wxWindow *parent) : EffectDialog(parent, _("Leveller"), PROCESS_EFFECT), mEffect(effect) { - mLevellerNumPasses = 0; + mLevellerNumPassesChoicIndex = 0;// mLevellerDbChoiceIndex = 0; Init(); } @@ -202,8 +202,6 @@ void LevellerDialog::PopulateOrExchange(ShuttleGui & S) wxArrayString db(Enums::NumDbChoices, Enums::GetDbChoices()); wxArrayString numPasses; - numPasses.Add(_("None-Skip")); - /* i18n-hint: Of strength of an effect. Not strongly.*/ numPasses.Add(_("Light")); numPasses.Add(_("Moderate")); @@ -229,7 +227,7 @@ void LevellerDialog::PopulateOrExchange(ShuttleGui & S) S.StartHorizontalLay(); { S.TieChoice(_("Degree of Leveling:"), - mLevellerNumPasses, + mLevellerNumPassesChoicIndex, &numPasses); } S.EndHorizontalLay(); @@ -258,7 +256,7 @@ void LevellerDialog::OnPreview(wxCommandEvent &event) int oldLevellerNumPasses = mEffect->mLevellerNumPasses; mEffect->mLevellerDbChoiceIndex = mLevellerDbChoiceIndex; - mEffect->mLevellerNumPasses = mLevellerNumPasses; + mEffect->mLevellerNumPasses = mLevellerNumPassesChoicIndex+1; mEffect->Preview(); diff --git a/src/effects/Leveller.h b/src/effects/Leveller.h index 956d97adf..29ec0c74e 100644 --- a/src/effects/Leveller.h +++ b/src/effects/Leveller.h @@ -87,7 +87,7 @@ class LevellerDialog: public EffectDialog public: int mLevellerDbChoiceIndex; - int mLevellerNumPasses; + int mLevellerNumPassesChoicIndex; }; #endif diff --git a/src/effects/ScoreAlignDialog.cpp b/src/effects/ScoreAlignDialog.cpp index 92558daa3..a6291f9c7 100644 --- a/src/effects/ScoreAlignDialog.cpp +++ b/src/effects/ScoreAlignDialog.cpp @@ -96,7 +96,7 @@ ScoreAlignDialog::ScoreAlignDialog(wxWindow *parent, ScoreAlignParams ¶ms) S.StartMultiColumn(3, wxEXPAND | wxALIGN_CENTER_VERTICAL); S.SetStretchyCol(1); - mFramePeriodLabel = S.AddVariableText(_("Frame Period:"), true, + mFramePeriodLabel = S.AddVariableText(_("Frame Period")+wxT(":"), true, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); S.SetStyle(wxSL_HORIZONTAL); mFramePeriodSlider = S.Id(ID_FRAMEPERIOD).AddSlider(wxT(""), @@ -106,7 +106,7 @@ ScoreAlignDialog::ScoreAlignDialog(wxWindow *parent, ScoreAlignParams ¶ms) mFramePeriodText = S.AddVariableText(SA_DFT_FRAME_PERIOD_TEXT, true, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL); - mWindowSizeLabel = S.AddVariableText(_("Window Size:"), true, + mWindowSizeLabel = S.AddVariableText(_("Window Size")+wxT(":"), true, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); S.SetStyle(wxSL_HORIZONTAL); mWindowSizeSlider = S.Id(ID_WINDOWSIZE).AddSlider(wxT(""), @@ -136,7 +136,11 @@ ScoreAlignDialog::ScoreAlignDialog(wxWindow *parent, ScoreAlignParams ¶ms) mSilenceThresholdText = S.AddVariableText(SA_DFT_SILENCE_THRESHOLD_TEXT, true, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL); - mPresmoothLabel = S.AddVariableText(_("Presmooth Time:"), true, + /* i18n-hint: The English would be clearer if it had 'Duration' rather than 'Time' + This is a new experiemtnal effect, and until we have it documented in the user + manual we don't have a clear description of what this parameter does. + It is OK to leave it in English. */ + mPresmoothLabel = S.AddVariableText(_("Presmooth Time")+wxT(":"), true, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); S.SetStyle(wxSL_HORIZONTAL); mPresmoothSlider = S.Id(ID_PRESMOOTH).AddSlider(wxT(""), @@ -145,7 +149,11 @@ ScoreAlignDialog::ScoreAlignDialog(wxWindow *parent, ScoreAlignParams ¶ms) mPresmoothText = S.AddVariableText(SA_DFT_PRESMOOTH_TIME_TEXT, true, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL); - mLineTimeLabel = S.AddVariableText(_("Line Time:"), true, + /* i18n-hint: The English would be clearer if it had 'Duration' rather than 'Time' + This is a new experiemtnal effect, and until we have it documented in the user + manual we don't have a clear description of what this parameter does. + It is OK to leave it in English. */ + mLineTimeLabel = S.AddVariableText(_("Line Time")+wxT(":"), true, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); S.SetStyle(wxSL_HORIZONTAL); mLineTimeSlider = S.Id(ID_LINETIME).AddSlider(wxT(""), @@ -154,7 +162,11 @@ ScoreAlignDialog::ScoreAlignDialog(wxWindow *parent, ScoreAlignParams ¶ms) mLineTimeText = S.AddVariableText(SA_DFT_LINE_TIME_TEXT, true, wxALIGN_LEFT | wxALIGN_CENTER_VERTICAL); - mSmoothTimeLabel = S.AddVariableText(_("Smooth Time:"), true, + /* i18n-hint: The English would be clearer if it had 'Duration' rather than 'Time' + This is a new experiemtnal effect, and until we have it documented in the user + manual we don't have a clear description of what this parameter does. + It is OK to leave it in English. */ + mSmoothTimeLabel = S.AddVariableText(_("Smooth Time")+wxT(":"), true, wxALIGN_RIGHT | wxALIGN_CENTER_VERTICAL); S.SetStyle(wxSL_HORIZONTAL); mSmoothTimeSlider = S.Id(ID_SMOOTHTIME).AddSlider(wxT(""), diff --git a/src/effects/TimeScale.cpp b/src/effects/TimeScale.cpp index 6369934b1..2e09d1ce2 100644 --- a/src/effects/TimeScale.cpp +++ b/src/effects/TimeScale.cpp @@ -304,8 +304,11 @@ void TimeScaleDialog::PopulateOrExchange(ShuttleGui & S) S.StartHorizontalLay(wxEXPAND); { S.SetStyle(wxSL_HORIZONTAL); + /* i18n-hint: Transients are sounds like the onset of cymbals or drums. + They can get 'blurred' by sound stretching. This checkbox option + may make them sharper again. */ m_pCheckBox_PreAnalyze = S.Id(ID_CHECKBOX_PREANALYZE) - .AddCheckBox(wxT("Dynamic Transient Sharpening"), wxT("Dynamic Transient Sharpening")); + .AddCheckBox(_("Dynamic Transient Sharpening"), wxT("false")); } S.EndHorizontalLay(); } diff --git a/src/effects/ToneGen.cpp b/src/effects/ToneGen.cpp index c148504df..cfec3677e 100644 --- a/src/effects/ToneGen.cpp +++ b/src/effects/ToneGen.cpp @@ -158,6 +158,10 @@ bool EffectToneGen::MakeTone(float *buffer, sampleCount len) Local variables are declared inside respective branch, globals are declared up. */ + bool bLogInterpolation = mbLogInterpolation; + if( abs( frequency[1]-frequency[0] ) < 0.000000001 ) + bLogInterpolation = true; + // this for log interpolation if( mbLogInterpolation ) { diff --git a/src/effects/TruncSilence.cpp b/src/effects/TruncSilence.cpp index ae7d5d516..65ab2d49c 100644 --- a/src/effects/TruncSilence.cpp +++ b/src/effects/TruncSilence.cpp @@ -891,7 +891,6 @@ void TruncSilenceDialog::PopulateOrExchange(ShuttleGui & S) 10); /* i18n-hint: Leave as is unless your language has a different way to show ratios like 5:1*/ S.AddUnits( _(":1") ); - //S.AddUnits(_("(9999999 or greater is off)")); S.TieChoice(_("Threshold for silence:"), mEffect->mTruncDbChoiceIndex, &choices);