Re: reset Preferences CFG file
Posted: Wed Dec 03, 2014 2:43 pm
So where are we going with the single button in Prefs, as per Ed's patch? I've tested it on all three platforms.
Gale
Gale
For questions, answers and opinions
https://forum.audacityteam.org/
My external reset app should not be too difficult to compile on Mac and Linux. Can you compile any of the wxWidgets sample applications? I started with the controls sample. Start with Windows:Gale Andrews wrote:Leland has not found a way yet to make your Windows external reset app into a Mac app.
Code: Select all
makeIf we distribute an external application it should come with all three platforms.Gale Andrews wrote: I am hoping we would distribute the external app with Audacity on Windows and Mac. So nothing to download that they did not already download.
Code: Select all
Find all "wxT("Audacity")", Match case, Whole word, Subfolders, Find Results 2, Entire Solution, "*.cpp;*.h;"
D:AudacitySVNsrcAboutDialog.cpp(292): S.StartNotebookPage( wxT("Audacity") );
D:AudacitySVNsrcAudacityApp.cpp(1038): wxString vendorName = wxT("Audacity");
D:AudacitySVNsrcAudacityApp.cpp(1039): wxString appName = wxT("Audacity");
D:AudacitySVNsrcProject.cpp(736): : wxFrame(parent, id, wxT("Audacity"), pos, size),
D:AudacitySVNsrcProject.cpp(1177): name = wxT("Audacity");
D:AudacitySVNsrceffectsnyquistNyquist.cpp(165): return wxT("Audacity");
Matching lines: 6 Matching files: 4 Total files searched: 850Code: Select all
/**********************************************************************
Audacity: A Digital Audio Editor
Audacity(R) is copyright (c) 1999-2011 Audacity Team.
License: GPL v2. See License.txt.
AudacityName.h
********************************************************************//*!
file AudacityName.h
This is just to specify the name Audacity. All files which need
to use wxT("Audacity") should include this.
*//********************************************************************/
#ifndef __AUDACITY_NAME_H__
#define __AUDACITY_NAME_H__
static wxString gAudacity_Name(wxT("Audacity"));
#endif // __AUDACITY_NAME_H__
Code: Select all
S.StartNotebookPage(gAudacity_Name);Code: Select all
// AUDACITY_NAME is legitimately used on some *nix configurations.Code: Select all
// LL: Moved here from InitPreferences() to ensure VST effect
// discovery writes configuration to the correct directory
// on OSX with case-sensitive file systems.
#ifdef AUDACITY_NAME
wxString appName = wxT(AUDACITY_NAME);
wxString vendorName = wxT(AUDACITY_NAME);
#else
wxString vendorName = wxT("Audacity");
wxString appName = wxT("Audacity");
#endif
wxTheApp->SetVendorName(vendorName);
wxTheApp->SetAppName(appName);The only one of those that I know about is:Edgar wrote:From the above we can see that wxT("Audacity") is redefined every time it is used (five times). This is very poor programming technique, it should be defined once in a header file
Code: Select all
D:AudacitySVNsrceffectsnyquistNyquist.cpp(165): return wxT("Audacity");Code: Select all
wxString EffectNyquist::GetVendor()
{
if (GetID() == wxT("nyquist prompt"))
{
return wxT("Audacity");
}
return mAuthor;
}On Linux the convention is to package separate applications separately. Thus the "reset app" would be a separate package from the "audacity" application. The "reset app" could be listed as a "recommend" type dependency, but as it is not "required" for running Audacity, it is a combination of the package maintainer's decision and the user's package installation settings, whether to pull in the "reset app" when installing Audacity. I would guess that most package maintainers would not pull in the external "reset app".Edgar wrote:If we distribute an external application it should come with all three platforms.
I stand by my contention even in this case. The intention is clearly to return vendorName and if we ever change vendorName we would almost certainly want the change to proliferate into NyquistEffect.GetID. 15 years from now if we change the branding name we would almost certainly pick up the two instances of vendorName and appName but could easily miss the obscure Nyquist reference.steve wrote: The only one of those that I know about is:Looking at that in context, we see that it is just a string that is returned by the Nyquist PromptCode: Select all
D:AudacitySVNsrceffectsnyquistNyquist.cpp(165): return wxT("Audacity");
Even if the two apps are conjoined at the hip as it were? On Windows it is quite common to have helper applications in the same folder as the basic application. Generally the basic application would execute these helper applications conditionally - not all helper applications would be executed every time the basic application was executed. Occasionally there are helper applications which are designed to be launched by the user.steve wrote:On Linux the convention is to package separate applications separately.Edgar wrote:If we distribute an external application it should come with all three platforms.
"no more difficult" - it's been so long since I played with Linux I don't remember the details. Generically, resetting manually requires:steve wrote: Also, on Linux, it is no more difficult to reset Audacity preferences manually than would be to run an external "reset app".
In this case the Audacity Development Team would have determined that it is "required", it would be part of the Audacity source code and would be created along with Audacity.exe when one issues the "make" command.steve wrote:but as it is not "required" for running Audacity, it is a combination of the package maintainer's decision and the user's package installation settings, whether to pull in the "reset app" when installing Audacity. I would guess that most package maintainers would not pull in the external "reset app".
Isn't the "vendor" (aka "author" / "publisher") the person/company/organisation that originated the plugin?Edgar wrote:The intention is clearly to return vendorName and if we ever change vendorName we would almost certainly want the change to proliferate into NyquistEffect.GetID. 15 years from now if we change the branding name we would almost certainly pick up the two instances of vendorName and appName but could easily miss the obscure Nyquist reference.
No Linux distributions that I know of include the manual in the Audacity package. In fact, I don't know of any distribution that even packages the manual.Edgar wrote:Even if the two apps are conjoined at the hip as it were?
There are several ways that work for Audacity 2.1 on Linux. Here are two methods:Edgar wrote:"no more difficult" - it's been so long since I played with Linux I don't remember the details. Generically, resetting manually requires:
Code: Select all
rm ~/.audacity-data/audacity.cfgThere are several methods that work on Linux. Here are 3:Edgar wrote:resetting via external application:
Code: Select all
name-of-reset-applicationCode: Select all
"fully qualified path to name-of-reset-application"