void GUIPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Display")); { S.TieCheckBox(_("&Ergonomic order of Transport Toolbar buttons"), wxT("/GUI/ErgonomicTransportButtons"), true); S.TieCheckBox(_("S&how 'How to Get Help' dialog box at program start up"), wxT("/GUI/ShowSplashScreen"), true); S.AddSpace(10); S.StartMultiColumn(2); { const wxString defaultRange = wxString::Format(wxT("%d"), ENV_DB_RANGE); S.TieChoice(_("Meter dB &range:"), ENV_DB_KEY, defaultRange, mRangeChoices, mRangeCodes); S.SetSizeHints(mRangeChoices); S.TieChoice(_("&Language:"), wxT("/Locale/Language"), wxT(""), mLangNames, mLangCodes); S.SetSizeHints(mLangNames); S.TieChoice(_("Location of &Manual:"), wxT("/GUI/Help"), wxT("Local"), mHtmlHelpChoices, mHtmlHelpCodes); S.SetSizeHints(mHtmlHelpChoices); } S.EndMultiColumn(); } S.EndStatic(); S.StartStatic(_("Behaviors")); { S.TieCheckBox(_("&Beep on completion of longer activities"), wxT("/GUI/BeepOnCompletion"), false); S.TieCheckBox(_("Re&tain labels if selection snaps to a label edge"), wxT("/GUI/RetainLabels"), false); #ifdef EXPERIMENTAL_OUTPUT_DISPLAY S.TieCheckBox(_("&Display a mono channel as virtual stereo"), wxT("/GUI/MonoAsVirtualStereo"), false); #endif } S.EndStatic(); }
void TracksBehaviorsPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartScroller(); S.StartStatic(_("Behaviors")); { S.TieCheckBox(_("A&uto-select, if selection required"), wxT("/GUI/SelectAllOnNone"), false); /* i18n-hint: Cut-lines are lines that can expand to show the cut audio.*/ S.TieCheckBox(_("Enable cut &lines"), wxT("/GUI/EnableCutLines"), false); S.TieCheckBox(_("Enable &dragging selection edges"), wxT("/GUI/AdjustSelectionEdges"), true); S.TieCheckBox(_("Editing a clip can &move other clips"), wxT("/GUI/EditClipCanMove"), true); S.TieCheckBox(_("\"Move track focus\" c&ycles repeatedly through tracks"), wxT("/GUI/CircularTrackNavigation"), false); S.TieCheckBox(_("&Type to create a label"), wxT("/GUI/TypeToCreateLabel"), true); S.TieCheckBox(_("Use dialog for the &name of a new label"), wxT("/GUI/DialogForNameNewLabel"), false); #ifdef EXPERIMENTAL_SCROLLING_LIMITS S.TieCheckBox(_("Enable scrolling left of &zero"), ScrollingPreferenceKey(), ScrollingPreferenceDefault()); #endif S.TieCheckBox(_("Advanced &vertical zooming"), wxT("/GUI/VerticalZooming"), false); S.AddSpace(10); S.StartMultiColumn(2); { S.TieChoice(_("Solo &Button:"), wxT("/GUI/Solo"), wxT("Standard"), mSoloChoices, mSoloCodes); } S.EndMultiColumn(); } S.EndStatic(); S.EndScroller(); }
void ModulePrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Enable these Modules (if present), next time Audacity is started")); { S.AddFixedText(_("These are experimental. Enable them only if you've read the manual\nand know what you are doing.") ); S.TieCheckBox(_("mod-&script-pipe"), wxT("/Module/mod-script-pipe"), false); S.TieCheckBox(_("mod-&nyq-bench"), wxT("/Module/mod-nyq-bench"), false); S.TieCheckBox(_("mod-&track-panel"), wxT("/Module/mod-track-panel"), false); } S.EndStatic(); }
/// Create the dialog contents, or exchange data with it. void SmartRecordPrefs::PopulateOrExchange( ShuttleGui & S) { S.StartStatic( _("Pause Recording on Silence") ); { S.TieCheckBox( _("Pause Recording on Silence"), wxT("/AudioIO/PauseRecOnSilence"),false); S.StartMultiColumn(2, wxEXPAND); S.SetStretchyCol(1); S.TieSlider(_("Silence level (dB):"), wxT("/AudioIO/SilenceLevel"), -50, 0, -60); S.EndMultiColumn(); } S.EndStatic(); }
void WarningsPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Show Warnings/Prompts")); { S.TieCheckBox(_("When saving &projects"), wxT("/Warnings/FirstProjectSave"), true); S.TieCheckBox(_("When saving &empty project"), wxT("/GUI/EmptyCanBeDirty"), true); S.TieCheckBox(_("When &disk space is getting low"), wxT("/Warnings/DiskSpaceWarning"), true); S.TieCheckBox(_("When mixing down to &stereo during export"), wxT("/Warnings/MixStereo"), true); S.TieCheckBox(_("When mixing down to &mono during export"), wxT("/Warnings/MixMono"), true); } S.EndStatic(); }
/// Defines the dialog and does data exchange with it. void BatchPrefs::PopulateOrExchange( ShuttleGui & S ) { S.StartHorizontalLay( wxEXPAND, 0 ); S.SetBorder( 2 ); S.StartStatic( _("Behaviors"),1 ); { #ifdef __WXDEBUG__ S.TieCheckBox( _("&Don't apply effects in batch mode"), wxT("/Batch/Debug"), false); #endif } S.EndStatic(); S.EndHorizontalLay(); return; }
void DirectoriesPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Temporary files directory")); { S.StartMultiColumn(3, wxEXPAND); { S.SetStretchyCol(1); S.Id(TempDirID); mTempDir = S.TieTextBox(_("&Location:"), wxT("/Directories/TempDir"), wxT(""), 30); S.Id(ChooseButtonID); S.AddButton(_("C&hoose...")); S.AddFixedText(_("Free Space:")); mFreeSpace = S.AddVariableText(wxT("")); } S.EndMultiColumn(); } S.EndStatic(); #ifdef DEPRECATED_AUDIO_CACHE // See http://bugzilla.audacityteam.org/show_bug.cgi?id=545. S.StartStatic(_("Audio cache")); { S.TieCheckBox(_("Play and/or record using &RAM (useful for slow drives)"), wxT("/Directories/CacheBlockFiles"), false); S.StartTwoColumn(); { S.TieNumericTextBox(_("Mi&nimum Free Memory (MB):"), wxT("/Directories/CacheLowMem"), 16, 9); } S.EndTwoColumn(); S.AddVariableText(_("If the available system memory falls below this value, audio will no longer\nbe cached in memory and will be written to disk."))->Wrap(600); } S.EndStatic(); #endif // DEPRECATED_AUDIO_CACHE }
void DirectoriesPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Temporary files directory")); { S.StartMultiColumn(3, wxEXPAND); { S.SetStretchyCol(1); S.Id(TempDirID); mTempDir = S.TieTextBox(_("Location:"), wxT("/Directories/TempDir"), wxT(""), 30); S.Id(ChooseButtonID); S.AddButton(_("Choose...")); S.AddFixedText(_("Free Space:")); mFreeSpace = S.AddVariableText(wxT("")); } S.EndMultiColumn(); } S.EndStatic(); S.StartStatic(_("Audio cache")); { S.TieCheckBox(_("Play and/or record using RAM (useful for slow drives)"), wxT("/Directories/CacheBlockFiles"), false); S.StartTwoColumn(); { S.TieTextBox(_("Minimum Free Memory (MB):"), wxT("/Directories/CacheLowMem"), 16, 9); } S.EndTwoColumn(); S.AddVariableText(_("If the available system memory falls below this value, audio will no longer\nbe cached in memory and will be written to disk."))->Wrap(600); } S.EndStatic(); }
void EffectsPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Enable")); { #if USE_LADSPA S.TieCheckBox(_("LADSPA effects"), wxT("/Ladspa/Enable"), true); #endif #if USE_NYQUIST S.TieCheckBox(_("Nyquist effects"), wxT("/Nyquist/Enable"), true); #endif #if USE_VAMP S.TieCheckBox(_("VAMP effects"), wxT("/VAMP/Enable"), true); #endif S.AddFixedText(_("Restart Audacity to apply changes.")); } S.EndStatic(); #if USE_AUDIO_UNITS S.StartStatic(_("Audio Unit Effects")); { S.TieCheckBox(_("Enable Audio Unit effects"), wxT("/AudioUnits/Enable"), true); S.TieCheckBox(_("Display Audio Unit effects in graphical mode"), wxT("/AudioUnits/GUI"), true); #if 0 S.TieCheckBox(_("Rescan VST effects next time Audacity is started"), wxT("/VST/Rescan"), false); #endif } S.EndStatic(); #endif #if USE_VST S.StartStatic(_("VST Effects")); { S.TieCheckBox(_("Enable VST effects"), wxT("/VST/Enable"), true); S.TieCheckBox(_("Display VST effects in graphical mode"), wxT("/VST/GUI"), true); S.TieCheckBox(_("Rescan VST effects next time Audacity is started"), wxT("/VST/Rescan"), false); } S.EndStatic(); #endif }
void EffectsPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartScroller(); S.StartStatic(_("Enable Effects")); { #if USE_AUDIO_UNITS S.TieCheckBox(_("Audio Unit"), wxT("/AudioUnit/Enable"), true); #endif // JKC: LADSPA, LV2, Nyquist, VST, VAMP should not be translated. #if USE_LADSPA S.TieCheckBox(wxT("&LADSPA"), wxT("/Ladspa/Enable"), true); #endif #if USE_LV2 S.TieCheckBox(wxT("LV&2"), wxT("/LV2/Enable"), true); #endif #if USE_NYQUIST S.TieCheckBox(wxT("N&yquist"), wxT("/Nyquist/Enable"), true); #endif #if USE_VAMP S.TieCheckBox(wxT("&Vamp"), wxT("/VAMP/Enable"), true); #endif #if USE_VST S.TieCheckBox(wxT("V&ST"), wxT("/VST/Enable"), true); #endif } S.EndStatic(); S.StartStatic(_("Effect Options")); { S.StartMultiColumn(2); { wxArrayString visualgroups; wxArrayString prefsgroups; visualgroups.Add(_("Sorted by Effect Name")); visualgroups.Add(_("Sorted by Publisher and Effect Name")); visualgroups.Add(_("Sorted by Type and Effect Name")); visualgroups.Add(_("Grouped by Publisher")); visualgroups.Add(_("Grouped by Type")); prefsgroups.Add(wxT("sortby:name")); prefsgroups.Add(wxT("sortby:publisher:name")); prefsgroups.Add(wxT("sortby:type:name")); prefsgroups.Add(wxT("groupby:publisher")); prefsgroups.Add(wxT("groupby:type")); wxChoice *c = S.TieChoice(_("S&ort or Group:"), wxT("/Effects/GroupBy"), wxT("name"), visualgroups, prefsgroups); c->SetMinSize(c->GetBestSize()); S.TieNumericTextBox(_("&Maximum effects per group (0 to disable):"), wxT("/Effects/MaxPerGroup"), #if defined(__WXGTK__) 15, #else 0, #endif 5); } S.EndMultiColumn(); } S.EndStatic(); #ifndef EXPERIMENTAL_EFFECT_MANAGEMENT S.StartStatic(_("Plugin Options")); { S.TieCheckBox(_("Check for updated plugins when Audacity starts"), wxT("/Plugins/CheckForUpdates"), true); S.TieCheckBox(_("Rescan plugins next time Audacity is started"), wxT("/Plugins/Rescan"), false); } S.EndStatic(); #endif #ifdef EXPERIMENTAL_EQ_SSE_THREADED S.StartStatic(_("Instruction Set")); { S.TieCheckBox(_("&Use SSE/SSE2/.../AVX"), wxT("/SSE/GUI"), true); } S.EndStatic(); #endif S.EndScroller(); }
void ExtImportPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.TieCheckBox(_("Attempt to use filter in OpenFile dialog first"), wxT("/ExtendedImport/OverrideExtendedImportByOpenFileDialogChoice"), true); S.StartStatic(_("Rules to choose import filters"), 1); { S.SetSizerProportion(1); S.StartHorizontalLay (wxEXPAND, 1); { bool fillRuleTable = false; if (RuleTable == NULL) { RuleTable = new Grid(S.GetParent(),EIPRuleTable); RuleTable->SetColLabelSize(RuleTable->GetDefaultRowSize()); #if EXTIMPORT_MIME_SUPPORT RuleTable->CreateGrid (0, 2, wxGrid::wxGridSelectRows); #else RuleTable->CreateGrid (0, 1, wxGrid::wxGridSelectRows); #endif RuleTable->DisableDragColMove (); RuleTable->DisableDragRowSize (); RuleTable->SetDefaultCellAlignment(wxALIGN_LEFT, wxALIGN_CENTER); RuleTable->SetColLabelValue (0, _("File extensions")); #if EXTIMPORT_MIME_SUPPORT RuleTable->SetColLabelValue (1, _("Mime-types")); #endif RuleTable->SetRowLabelSize (0); RuleTable->SetSelectionMode (wxGrid::wxGridSelectRows); RuleTable->AutoSizeColumns (); RuleTable->SetDropTarget (dragtarget1); RuleTable->EnableDragCell (true); fillRuleTable = true; } S.AddWindow(RuleTable, wxEXPAND | wxALL); PluginList = S.Id(EIPPluginList).AddListControl (); if (fillRuleTable) { PluginList->SetSingleStyle (wxLC_REPORT, true); PluginList->SetSingleStyle (wxLC_SINGLE_SEL, true); PluginList->InsertColumn (0, _("Importer order")); PluginList->SetDropTarget (dragtarget2); ExtImportItems *items = wxGetApp().mImporter->GetImportItems(); for (unsigned int i = 0; i < items->Count(); i++) AddItemToTable (i, &(*items)[i]); if (items->Count() > 0) { RuleTable->SelectRow(0); RuleTable->SetGridCursor(0,0); } } } S.EndHorizontalLay(); S.StartHorizontalLay (wxSHRINK, 0); { MoveRuleUp = S.Id (EIPMoveRuleUp).AddButton (_("Move rule &up")); MoveRuleDown = S.Id (EIPMoveRuleDown).AddButton (_("Move rule &down")); MoveFilterUp = S.Id (EIPMoveFilterUp).AddButton (_("Move f&ilter up")); MoveFilterDown = S.Id (EIPMoveFilterDown).AddButton (_("Move &filter down")); } S.EndHorizontalLay(); S.StartHorizontalLay (wxSHRINK, 0); { AddRule = S.Id (EIPAddRule).AddButton (_("&Add new rule")); DelRule = S.Id (EIPDelRule).AddButton (_("De&lete selected rule")); } S.EndHorizontalLay(); } S.EndStatic(); Layout(); Fit(); SetMinSize(GetSize()); }
void RecordingPrefs::PopulateOrExchange(ShuttleGui & S) { wxTextCtrl *w; S.SetBorder(2); S.StartStatic(_("Playthrough")); { S.TieCheckBox(_("Overdub: &Play other tracks while recording new one"), wxT("/AudioIO/Duplex"), true); #if defined(__WXMAC__) S.TieCheckBox(_("&Hardware Playthrough: Listen while recording or monitoring new track"), wxT("/AudioIO/Playthrough"), false); #endif S.TieCheckBox(_("&Software Playthrough: Listen while recording or monitoring new track"), wxT("/AudioIO/SWPlaythrough"), false); #if !defined(__WXMAC__) S.AddUnits(wxString(wxT(" ")) + _("(uncheck when recording \"stereo mix\")")); #endif } S.EndStatic(); S.StartStatic( _("Latency")); { S.StartThreeColumn(); { // only show the following controls if we use Portaudio v19, because // for Portaudio v18 we always use default buffer sizes w = S.TieNumericTextBox(_("Audio to &buffer:"), wxT("/AudioIO/LatencyDuration"), DEFAULT_LATENCY_DURATION, 9); S.AddUnits(_("milliseconds (higher = more latency)")); w->SetName(w->GetName() + wxT(" ") + _("milliseconds (higher = more latency)")); w = S.TieNumericTextBox(_("L&atency correction:"), wxT("/AudioIO/LatencyCorrection"), DEFAULT_LATENCY_CORRECTION, 9); S.AddUnits(_("milliseconds (negative = backwards)")); w->SetName(w->GetName() + wxT(" ") + _("milliseconds (negative = backwards)")); } S.EndThreeColumn(); } S.EndStatic(); S.StartStatic(_("Sound Activated Recording")); { S.TieCheckBox(_("Sound Activated &Recording"), wxT("/AudioIO/SoundActivatedRecord"), false); S.StartMultiColumn(2, wxEXPAND); { S.SetStretchyCol(1); int dBRange = gPrefs->Read(wxT("/GUI/EnvdBRange"), ENV_DB_RANGE); S.TieSlider(_("Sound Activation Le&vel (dB):"), wxT("/AudioIO/SilenceLevel"), -50, 0, -dBRange); } S.EndMultiColumn(); } S.EndStatic(); #ifdef AUTOMATED_INPUT_LEVEL_ADJUSTMENT S.StartStatic(_("AutomatedRecording Level Adjustment")); { S.TieCheckBox(_("Enable Automated Recordingt Level Adjustment."), wxT("/AudioIO/AutomatedInputLevelAdjustment"), false); S.StartMultiColumn(2, wxEXPAND); { S.SetStretchyCol(1); /* i18n-hint: Desired maximum (peak) volume for sound */ S.TieSlider(_("Target Peak:"), wxT("/AudioIO/TargetPeak"), AILA_DEF_TARGET_PEAK, 100, 0); S.TieSlider(_("Within:"), wxT("/AudioIO/DeltaPeakVolume"), AILA_DEF_DELTA_PEAK, 100, 0); } S.EndMultiColumn(); S.StartThreeColumn(); { S.TieNumericTextBox(_("Analysis Time:"), wxT("/AudioIO/AnalysisTime"), AILA_DEF_ANALYSIS_TIME, 9); S.AddUnits(_("milliseconds (time of one analysis)")); S.TieNumericTextBox(_("Number of consecutive analysis:"), wxT("/AudioIO/NumberAnalysis"), AILA_DEF_NUMBER_ANALYSIS, 2); S.AddUnits(_("0 means endless")); } S.EndThreeColumn(); } S.EndStatic(); #endif }
void GUIPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartScroller(); S.StartStatic(_("Display")); { S.StartMultiColumn(2); { #ifdef EXPERIMENTAL_DA const wxString defaultTheme = wxT("dark"); #else const wxString defaultTheme = wxT("light"); #endif const wxString defaultRange = wxString::Format(wxT("%d"), ENV_DB_RANGE); S.TieChoice(_("&Language:"), wxT("/Locale/Language"), wxT(""), mLangNames, mLangCodes); S.SetSizeHints(mLangNames); S.TieChoice(_("Location of &Manual:"), wxT("/GUI/Help"), wxT("Local"), mHtmlHelpChoices, mHtmlHelpCodes); S.SetSizeHints(mHtmlHelpChoices); S.TieChoice(_("Th&eme:"), wxT("/GUI/Theme"), defaultTheme, mThemeChoices, mThemeCodes); S.SetSizeHints(mThemeChoices); S.TieChoice(_("Meter dB &range:"), ENV_DB_KEY, defaultRange, mRangeChoices, mRangeCodes); S.SetSizeHints(mRangeChoices); } S.EndMultiColumn(); // S.AddSpace(10); // JKC: This is a silly preference. Kept here as a reminder that we may // later want to have configurable button order. // S.TieCheckBox(_("&Ergonomic order of Transport Toolbar buttons"), // wxT("/GUI/ErgonomicTransportButtons"), // true); } S.EndStatic(); S.StartStatic(_("Show")); { S.TieCheckBox(_("'How to Get &Help' at launch"), wxT("/GUI/ShowSplashScreen"), true); S.TieCheckBox(_("E&xtra menus"), wxT("/GUI/ShowExtraMenus"), false); #ifdef EXPERIMENTAL_THEME_PREFS // We do not want to make this option mainstream. It's a // convenience for developers. S.TieCheckBox(_("Show alternative &styling (Mac vs PC)"), wxT("/GUI/ShowMac"), false); #endif } S.EndStatic(); S.StartStatic(_("Behaviors")); { S.TieCheckBox(_("&Beep on completion of longer activities"), wxT("/GUI/BeepOnCompletion"), false); S.TieCheckBox(_("Re&tain labels if selection snaps to a label"), wxT("/GUI/RetainLabels"), false); S.TieCheckBox(_("B&lend system and Audacity theme"), wxT("/GUI/BlendThemes"), true); } S.EndStatic(); S.EndScroller(); }
void TracksPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Display")); { S.TieCheckBox(_("&Update display while playing"), wxT("/GUI/AutoScroll"), true); S.TieCheckBox(_("Automatically &fit tracks vertically zoomed"), wxT("/GUI/TracksFitVerticallyZoomed"), false); S.AddSpace(10); S.StartMultiColumn(2); { S.TieChoice(_("Default &view mode:"), wxT("/GUI/DefaultViewModeNew"), 0, mViewChoices, mViewCodes); S.SetSizeHints(mViewChoices); S.TieTextBox(_("Default audio track &name:"), wxT("/GUI/TrackNames/DefaultTrackName"), _("Audio Track"), 30); } S.EndMultiColumn(); S.TieCheckBox(_("Sho&w audio track name as overlay"), wxT("/GUI/ShowTrackNameInWaveform"), false); } S.EndStatic(); S.StartStatic(_("Behaviors")); { S.TieCheckBox(_("&Select all audio in project, if none selected"), wxT("/GUI/SelectAllOnNone"), true); /* i18n-hint: cut-lines are a lines indicating where to cut.*/ S.TieCheckBox(_("Enable cu&t lines"), wxT("/GUI/EnableCutLines"), false); S.TieCheckBox(_("Enable &dragging of left and right selection edges"), wxT("/GUI/AdjustSelectionEdges"), true); S.TieCheckBox(_("\"Move track focus\" c&ycles repeatedly through tracks"), wxT("/GUI/CircularTrackNavigation"), false); S.TieCheckBox(_("Editing a clip can &move other clips"), wxT("/GUI/EditClipCanMove"), true); #ifdef EXPERIMENTAL_SCROLLING_LIMITS S.TieCheckBox(_("Enable scrolling left of &zero"), wxT("/GUI/ScrollBeyondZero"), false); #endif S.AddSpace(10); S.StartMultiColumn(2); { S.TieChoice(_("Solo &Button:"), wxT("/GUI/Solo"), wxT("Standard"), mSoloChoices, mSoloCodes); S.SetSizeHints(mSoloChoices); } S.EndMultiColumn(); } S.EndStatic(); }
/// This PopulateOrExchange function is a good example of mixing the fully /// automatic style of reading/writing from GUI to prefs with the partial form. /// /// You'll notice that some of the Tie functions have Prefs identifiers in them /// and others don't. void LibraryPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("MP3 Export Library")); { S.StartTwoColumn(); { S.AddVariableText(_("MP3 Library Version:"), true, wxALL | wxALIGN_RIGHT | wxALIGN_CENTRE_VERTICAL); mMP3Version = S.AddVariableText(wxT("9.99"), true, wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); S.AddVariableText(_("MP3 Library:"), true, wxALL | wxALIGN_RIGHT | wxALIGN_CENTRE_VERTICAL); wxButton *locate_button = S.Id(ID_MP3_FIND_BUTTON).AddButton(_("&Locate..."), wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); S.AddVariableText(_("LAME MP3 Library:"), true, wxALL | wxALIGN_RIGHT | wxALIGN_CENTRE_VERTICAL); wxButton *download_button = S.Id(ID_MP3_DOWN_BUTTON).AddButton(_("&Download"), wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); #ifdef DISABLE_DYNAMIC_LOADING_LAME locate_button->Enable(FALSE); download_button->Enable(FALSE); #else (void)locate_button; (void)download_button; #endif // DISABLE_DYNAMIC_LOADING_LAME } S.EndTwoColumn(); } S.EndStatic(); S.StartStatic(_("FFmpeg Import/Export Library")); { S.StartTwoColumn(); { S.AddVariableText(_("FFmpeg Library Version:"), true, wxALL | wxALIGN_RIGHT | wxALIGN_CENTRE_VERTICAL); #if defined(USE_FFMPEG) mFFmpegVersion = S.AddVariableText(_("No compatible FFmpeg library was found"), true, wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); #else mFFmpegVersion = S.AddVariableText(wxT("FFmpeg support is not compiled in"), true, wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); #endif S.AddVariableText(_("FFmpeg Library:"), true, wxALL | wxALIGN_RIGHT | wxALIGN_CENTRE_VERTICAL); S.Id(ID_FFMPEG_FIND_BUTTON); wxButton *bfnd = S.AddButton(_("Loca&te..."), wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); S.AddVariableText(_("FFmpeg Library:"), true, wxALL | wxALIGN_RIGHT | wxALIGN_CENTRE_VERTICAL); S.Id(ID_FFMPEG_DOWN_BUTTON); wxButton *bdwn = S.AddButton(_("Dow&nload"), wxALL | wxALIGN_LEFT | wxALIGN_CENTRE_VERTICAL); #if !defined(USE_FFMPEG) || defined(DISABLE_DYNAMIC_LOADING_FFMPEG) bdwn->Enable(FALSE); bfnd->Enable(FALSE); #else // fix compilation warnings about unused variables bfnd, bdwn; #endif } S.EndTwoColumn(); #ifdef EXPERIMENTAL_OD_FFMPEG wxCheckBox* checkbox = S.TieCheckBox(_("Allow &background on-demand loading"), wxT("/Library/FFmpegOnDemand"), false); #if !defined(USE_FFMPEG) checkbox->Enable(FALSE); #endif #endif } S.EndStatic(); }
/// Create the dialog contents, or exchange data with it. void ThemePrefs::PopulateOrExchange( ShuttleGui & S) { S.StartHorizontalLay(wxEXPAND,1); S.StartVerticalLay(0); S.StartStatic( _("Theme Cache - Images && Color")); { S.Id( idSaveThemeCache ).AddButton( _("Save Theme Cache")); S.Id( idLoadThemeCache ).AddButton( _("Load Theme Cache")); // This next button is only provided in Debug mode. // It is for developers who are compiling Audacity themselves // and who who wish to generate a new ThemeAsCeeCode.h and compile it in. #ifdef __WXDEBUG__ // S.Id( idSaveThemeAsCode ).AddButton( wxT("Save Code" )); S.Id( idSaveThemeAsCode ).AddButton( wxT("Output Sourcery" )); #endif S.Id( idReadThemeInternal ).AddButton( _("Defaults" )); S.TieCheckBox( _("Load Theme Cache At Startup"), wxT("/Theme/LoadAtStart"), false); } S.EndStatic(); // JKC: 'Ergonomic' details: // Theme components are used much less frequently than // the ImageCache. Yet it's easy to click them 'by mistake'. // // To reduce that risk, we use a separate box to separate them off. // And choose text on the buttons that is shorter, making the // buttons smaller and less tempting to click. S.StartStatic( _("Individual Theme Files"),1); { S.Id( idSaveThemeComponents ).AddButton( _("Save Files")); S.Id( idLoadThemeComponents ).AddButton( _("Load Files")); } S.EndStatic(); S.EndVerticalLay(); S.StartStatic( _("Info"), 1 ); { S.AddFixedText( _("Themability is an experimental feature.\n\n" wxT("To try it out, click \"Save Theme Cache\" then\n" ) wxT("find and modify the images and colors in \n" ) wxT("ImageCacheVxx.png using an image editor such \n" ) wxT("as the Gimp.\n\n") wxT("Click \"Load Theme Cache\" to load the changed images\n") wxT("and colors back into Audacity.\n\n") wxT("[Only the control toolbar and the colors on the \n") wxT("wavetrack are currently affected, even though the\n") wxT("image file shows other icons too.]\n")) ); #ifdef __WXDEBUG__ S.AddFixedText( _("You have compiled Audacity with an extra button, \n" wxT("'Output Sourcery'. This will save a C version of \n") wxT("the image cache that can be compiled in as a default.\n")) ); #endif S.AddFixedText( _("If 'Load Theme Cache At Startup' is checked, then \n" wxT("the Theme Cache will be loaded when the program \n") wxT("starts up.\n\n") wxT("Saving and loading individual theme files uses a \n") wxT("separate file for each image, but is otherwise the \n") wxT("same idea.\n\n")) ); } S.EndStatic(); }
void SpectrumPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("FFT Window")); { S.StartMultiColumn(2); { S.TieChoice(_("Window size") + wxString(wxT(":")), wxT("/Spectrum/FFTSize"), 256, mSizeChoices, mSizeCodes); S.SetSizeHints(mSizeChoices); S.TieChoice(_("Window type") + wxString(wxT(":")), wxT("/Spectrum/WindowType"), 3, mTypeChoices, mTypeCodes); S.SetSizeHints(mTypeChoices); } S.EndMultiColumn(); } S.EndStatic(); #ifdef EXPERIMENTAL_FFT_SKIP_POINTS wxArrayString wskipn; wxArrayInt wskipv; for (size_t i = 0; i < 7; i++) { wskipn.Add(wxString::Format(wxT("%d"), (1 << i) - 1)); wskipv.Add((1 << i) - 1); } S.StartStatic(_("FFT Skip Points")); { S.StartMultiColumn(2); { S.TieChoice(_("Skip Points") + wxString(wxT(":")), wxT("/Spectrum/FFTSkipPoints"), 0, wskipn, wskipv); S.SetSizeHints(wskipn); } S.EndMultiColumn(); } S.EndStatic(); #endif //EXPERIMENTAL_FFT_SKIP_POINTS S.StartStatic(_("Display")); { S.StartTwoColumn(); { mMinFreq = S.TieTextBox(_("Minimum Frequency (Hz):"), wxT("/Spectrum/MinFreq"), 0, 12); mMaxFreq = S.TieTextBox(_("Maximum Frequency (Hz):"), wxT("/Spectrum/MaxFreq"), 8000, 12); mGain = S.TieTextBox(_("Gain (dB):"), wxT("/Spectrum/Gain"), 20, 8); mRange = S.TieTextBox(_("Range (dB):"), wxT("/Spectrum/Range"), 80, 8); mFrequencyGain = S.TieTextBox(_("Frequency gain: (dB/dec)"), wxT("/Spectrum/FrequencyGain"), 0, 4); } S.EndTwoColumn(); S.TieCheckBox(_("Show the spectrum using &grayscale colors"), wxT("/Spectrum/Grayscale"), false); #ifdef EXPERIMENTAL_FFT_Y_GRID S.TieCheckBox(_("Show a grid along the &Y-axis"), wxT("/Spectrum/FFTYGrid"), false); #endif //EXPERIMENTAL_FFT_Y_GRID } S.EndStatic(); #ifdef EXPERIMENTAL_FIND_NOTES S.StartStatic(_("FFT Find Notes")); { S.StartTwoColumn(); { mFindNotesMinA = S.TieTextBox(_("Minimum Amplitude (dB):"), wxT("/Spectrum/FindNotesMinA"), -30L, 8); mFindNotesN = S.TieTextBox(_("Max. Number of Notes (1..128):"), wxT("/Spectrum/FindNotesN"), 5L, 8); } S.EndTwoColumn(); S.TieCheckBox(_("&Find Notes"), wxT("/Spectrum/FFTFindNotes"), false); S.TieCheckBox(_("&Quantize Notes"), wxT("/Spectrum/FindNotesQuantize"), false); } S.EndStatic(); #endif //EXPERIMENTAL_FIND_NOTES }
void AudioIOPrefs::PopulateOrExchange( ShuttleGui & S ) { /// \todo /// JKC: I think setting paths in gPrefs is bad practice. /// Suppose we are using gPrefs from elsewhere at the same time? /// Change these all to full paths? gPrefs->SetPath(wxT("/AudioIO")); S.SetBorder( 2 ); S.StartHorizontalLay(wxEXPAND, 0 ); S.StartStatic( _("Playback"),1 ); { S.StartMultiColumn(2, wxEXPAND); S.SetStretchyCol(1); S.TieChoice( _("Device") + wxString(wxT(":")), wxT("PlaybackDevice"), wxT(""), mmPlayNames, mmPlayLabels ); S.AddPrompt( _("Using:") ); wxString ver = _("Portaudio v"); #if USE_PORTAUDIO_V19 ver += wxT("19"); #else ver += wxT("18"); #endif S.AddFixedText( ver ); S.EndMultiColumn(); } S.EndStatic(); S.StartStatic( _("Recording"), 1 ); { S.StartMultiColumn(2, wxEXPAND); S.SetStretchyCol(1); S.TieChoice( _("Device") + wxString(wxT(":")), wxT("RecordingDevice"), wxT(""), mmRecordNames, mmRecordLabels ); S.TieChoice( _("Channels") + wxString(wxT(":")), wxT("RecordChannels"), 2, mmChannelNames, mmChannelLabels ); S.EndMultiColumn(); } S.EndStatic(); S.EndHorizontalLay(); S.StartStatic( _("Playthrough") ); { S.TieCheckBox( _("&Play other tracks while recording new one"), wxT("Duplex"),true); #ifdef __MACOSX__ S.TieCheckBox( _("&Hardware Playthrough (Play new track while recording it)"), wxT("Playthrough"),false); #endif S.TieCheckBox( _("&Software Playthrough (Play new track while recording it)"), wxT("SWPlaythrough"),false); } S.EndStatic(); S.StartHorizontalLay( wxEXPAND, 0 ); S.StartStatic( _("Cut Preview"),1 ); { S.StartThreeColumn(); S.TieTextBox( _("Play before cut region:"), wxT("CutPreviewBeforeLen"),1.0,9); S.AddUnits( _("seconds") ); S.TieTextBox( _("Play after cut region:"),wxT("CutPreviewAfterLen"), 1.0,9); S.AddUnits( _("seconds") ); S.EndThreeColumn(); } S.EndStatic(); S.StartStatic( _("Latency"),1 ); { S.StartThreeColumn(); #if USE_PORTAUDIO_V19 // only show the following controls if we use Portaudio v19, because // for Portaudio v19 we always use default buffer sizes S.TieTextBox( _("Audio to buffer:"),wxT("LatencyDuration"),100.0,9); S.AddUnits( _("milliseconds") ); #endif S.TieTextBox( _("Latency correction:"),wxT("LatencyCorrection"),0.0,9); S.AddUnits( _("milliseconds") ); S.EndThreeColumn(); } S.EndStatic(); S.EndHorizontalLay(); S.StartHorizontalLay( wxEXPAND, 0 ); S.StartStatic( _("Seek Time"),1 ); { S.StartThreeColumn(); S.TieTextBox( _("Short period:"), wxT("SeekShortPeriod"),1.0,9); S.AddUnits( _("seconds") ); S.TieTextBox( _("Long period:"),wxT("SeekLongPeriod"), 15.0,9); S.AddUnits( _("seconds") ); S.EndThreeColumn(); } S.EndStatic(); S.StartStatic( _("Effects Preview"),1 ); { S.StartThreeColumn(); S.TieTextBox( _("Play when previewing:"), wxT("EffectsPreviewLen"), 3.0,9); S.AddUnits( _("seconds") ); S.EndThreeColumn(); } gPrefs->SetPath(wxT("/")); }
void EffectsPrefs::PopulateOrExchange(ShuttleGui & S) { S.SetBorder(2); S.StartStatic(_("Enable Effects")); { #if USE_AUDIO_UNITS S.TieCheckBox(_("Audio Unit"), wxT("/AudioUnits/Enable"), true); #endif // JKC: LADSPA, LV2, Nyquist, VST, VAMP should not be translated. #if USE_LADSPA S.TieCheckBox(wxT("&LADSPA"), wxT("/Ladspa/Enable"), true); #endif #if USE_LV2 S.TieCheckBox(wxT("LV&2"), wxT("/LV2/Enable"), true); #endif #if USE_NYQUIST S.TieCheckBox(wxT("N&yquist"), wxT("/Nyquist/Enable"), true); #endif #if USE_VAMP S.TieCheckBox(wxT("&VAMP"), wxT("/VAMP/Enable"), true); #endif #if USE_VST S.TieCheckBox(wxT("V&ST"), wxT("/VST/Enable"), true); #endif S.AddFixedText(_("Restart Audacity to apply changes.")); } S.EndStatic(); #if USE_AUDIO_UNITS S.StartStatic(_("Audio Unit Effects")); { S.TieCheckBox(_("Display Audio Unit effects in Graphical Mode"), wxT("/AudioUnits/GUI"), true); #if 0 S.TieCheckBox(_("Rescan VST effects next time Audacity is started"), wxT("/VST/Rescan"), false); #endif } S.EndStatic(); #endif #if USE_VST S.StartStatic(_("VST Effects")); { S.TieCheckBox(_("&Display VST effects in Graphical Mode"), wxT("/VST/GUI"), true); S.TieCheckBox(_("&Rescan VST effects next time Audacity is started"), wxT("/VST/Rescan"), false); } S.EndStatic(); #endif #ifdef EXPERIMENTAL_EQ_SSE_THREADED S.StartStatic(_("Instruction Set")); { S.TieCheckBox(_("&Use SSE/SSE2/.../AVX"), wxT("/SSE/GUI"), true); } S.EndStatic(); #endif }
void SpectrumPrefs::PopulateOrExchange(ShuttleGui & S) { mPopulating = true; S.SetBorder(2); // S.StartStatic(_("Track Settings")); // { mDefaultsCheckbox = 0; if (mWt) { /* i18n-hint: use is a verb */ mDefaultsCheckbox = S.Id(ID_DEFAULTS).TieCheckBox(_("Use Preferences"), mDefaulted); } S.StartStatic(_("Scale")); { S.StartTwoColumn(); { S.Id(ID_SCALE).TieChoice(_("S&cale") + wxString(wxT(":")), *(int*)&mTempSettings.scaleType, &mScaleChoices); mMinFreq = S.Id(ID_MINIMUM).TieNumericTextBox(_("Mi&nimum Frequency (Hz):"), mTempSettings.minFreq, 12); mMaxFreq = S.Id(ID_MAXIMUM).TieNumericTextBox(_("Ma&ximum Frequency (Hz):"), mTempSettings.maxFreq, 12); } S.EndTwoColumn(); } S.EndStatic(); S.StartStatic(_("Colors")); { S.StartTwoColumn(); { mGain = S.Id(ID_GAIN).TieNumericTextBox(_("&Gain (dB):"), mTempSettings.gain, 8); mRange = S.Id(ID_RANGE).TieNumericTextBox(_("&Range (dB):"), mTempSettings.range, 8); mFrequencyGain = S.Id(ID_FREQUENCY_GAIN).TieNumericTextBox(_("Frequency g&ain (dB/dec):"), mTempSettings.frequencyGain, 4); } S.Id(ID_GRAYSCALE).TieCheckBox(_("S&how the spectrum using grayscale colors"), mTempSettings.isGrayscale); S.EndTwoColumn(); } S.EndStatic(); S.StartStatic(_("Algorithm")); { S.StartMultiColumn(2); { mAlgorithmChoice = S.Id(ID_ALGORITHM).TieChoice(_("A&lgorithm") + wxString(wxT(":")), *(int*)&mTempSettings.algorithm, &mAlgorithmChoices); S.Id(ID_WINDOW_SIZE).TieChoice(_("Window &size:"), mTempSettings.windowSize, &mSizeChoices); S.SetSizeHints(mSizeChoices); S.Id(ID_WINDOW_TYPE).TieChoice(_("Window &type:"), mTempSettings.windowType, &mTypeChoices); S.SetSizeHints(mTypeChoices); #ifdef EXPERIMENTAL_ZERO_PADDED_SPECTROGRAMS mZeroPaddingChoiceCtrl = S.Id(ID_PADDING_SIZE).TieChoice(_("&Zero padding factor") + wxString(wxT(":")), mTempSettings.zeroPaddingFactor, &mZeroPaddingChoices); S.SetSizeHints(mZeroPaddingChoices); #endif } S.EndMultiColumn(); } S.EndStatic(); #ifndef SPECTRAL_SELECTION_GLOBAL_SWITCH S.Id(ID_SPECTRAL_SELECTION).TieCheckBox(_("Ena&ble Spectral Selection"), mTempSettings.spectralSelection); #endif #ifdef EXPERIMENTAL_FFT_Y_GRID S.TieCheckBox(_("Show a grid along the &Y-axis"), mTempSettings.fftYGrid); #endif //EXPERIMENTAL_FFT_Y_GRID #ifdef EXPERIMENTAL_FIND_NOTES /* i18n-hint: FFT stands for Fast Fourier Transform and probably shouldn't be translated*/ S.StartStatic(_("FFT Find Notes")); { S.StartTwoColumn(); { mFindNotesMinA = S.TieNumericTextBox(_("Minimum Amplitude (dB):"), mTempSettings.fftFindNotes, 8); mFindNotesN = S.TieNumericTextBox(_("Max. Number of Notes (1..128):"), mTempSettings.findNotesMinA, 8); } S.EndTwoColumn(); S.TieCheckBox(_("&Find Notes"), mTempSettings.numberOfMaxima); S.TieCheckBox(_("&Quantize Notes"), mTempSettings.findNotesQuantize); } S.EndStatic(); #endif //EXPERIMENTAL_FIND_NOTES // S.EndStatic(); #ifdef SPECTRAL_SELECTION_GLOBAL_SWITCH S.StartStatic(_("Global settings")); { S.TieCheckBox(_("Ena&ble spectral selection"), SpectrogramSettings::Globals::Get().spectralSelection); } S.EndStatic(); #endif EnableDisableSTFTOnlyControls(); mPopulating = false; }
void SpectrumPrefs::PopulateOrExchange( ShuttleGui & S ) { wxArrayString windowTypeList; for(int i=0; i<NumWindowFuncs(); i++) windowTypeList.Add(WindowFuncName(i)); S.SetBorder( 2 ); S.StartHorizontalLay(wxEXPAND, 0 ); S.StartStatic( _("FFT Size"), 0 ); { S.StartRadioButtonGroup( wxT("/Spectrum/FFTSize"), 256 ); S.TieRadioButton( _("8 - most wideband"), 8); S.TieRadioButton( wxT("16"), 16); S.TieRadioButton( wxT("32"), 32); S.TieRadioButton( wxT("64"), 64); S.TieRadioButton( wxT("128"), 128); S.TieRadioButton( _("256 - default"), 256); S.TieRadioButton( wxT("512"), 512); S.TieRadioButton( wxT("1024"), 1024); S.TieRadioButton( wxT("2048"), 2048); #ifdef EXPERIMENTAL_FIND_NOTES S.TieRadioButton( wxT("4096"), 4096); S.TieRadioButton( wxT("8192"), 8192); S.TieRadioButton( wxT("16384"), 16384); S.TieRadioButton( _("32768 - most narrowband"),32768); #else S.TieRadioButton( _("4096 - most narrowband"),4096); #endif //LOGARITHMIC_SPECTRUM S.EndRadioButtonGroup(); // add choice for windowtype S.StartMultiColumn(2, wxCENTER); { S.TieChoice( _("Window type:"), windowType, &windowTypeList); S.SetSizeHints(-1,-1); } S.EndMultiColumn(); } S.EndStatic(); #ifdef EXPERIMENTAL_FFT_SKIP_POINTS S.StartHorizontalLay(wxEXPAND, 0 ); S.StartStatic( _("FFT Skip Points"), 0 ); { S.StartRadioButtonGroup(wxT("/Spectrum/FFTSkipPoints"), 0); S.TieRadioButton(wxT("0"), 0); S.TieRadioButton(wxT("1"), 1); S.TieRadioButton(wxT("3"), 3); S.TieRadioButton(wxT("7"), 7); S.TieRadioButton(wxT("15"), 15); S.TieRadioButton(wxT("31"), 31); S.TieRadioButton(wxT("63"), 63); S.EndRadioButtonGroup(); } S.EndStatic(); #endif //EXPERIMENTAL_FFT_SKIP_POINTS S.StartStatic( _("Display"),1 ); { // JC: For layout of mixtures of controls I prefer checkboxes on the right, // with everything in two columns over what we have here. S.TieCheckBox( _("&Grayscale"), wxT("/Spectrum/Grayscale"), false); S.StartTwoColumn(); // 2 cols because we have a control with a separate label. S.Id(ID_MINFREQUENCY).TieTextBox( _("Minimum Frequency (Hz):"), // prompt minFreqStr, // String to exchange with 12 // max number of characters (used to size the control). ); S.Id(ID_MAXFREQUENCY).TieTextBox( _("Maximum Frequency (Hz):"), // prompt maxFreqStr, // String to exchange with 12 // max number of characters (used to size the control). ); S.EndTwoColumn(); #ifdef EXPERIMENTAL_FFT_Y_GRID S.TieCheckBox( _("&Y-Grid"), wxT("/Spectrum/FFTYGrid"), false); #endif //EXPERIMENTAL_FFT_Y_GRID #ifdef EXPERIMENTAL_FIND_NOTES S.TieCheckBox( _("&Find Notes"), wxT("/Spectrum/FFTFindNotes"), false); S.TieCheckBox( _("&Quantize Notes"), wxT("/Spectrum/FindNotesQuantize"), false); S.StartTwoColumn(); // 2 cols because we have a control with a separate label. S.Id(ID_FIND_NOTES_MIN_A).TieTextBox( _("Minimum Amplitude (dB):"), // prompt findNotesMinAStr, // String to exchange with 8 // max number of characters (used to size the control). ); S.Id(ID_FIND_NOTES_N).TieTextBox( _("Max. Number of Notes (1..128):"), // prompt findNotesNStr, // String to exchange with 8 // max number of characters (used to size the control). ); S.EndTwoColumn(); #endif //EXPERIMENTAL_FIND_NOTES } S.EndStatic(); S.EndHorizontalLay(); }