NumeRe v1.1.4
NumeRe: Framework für Numerische Rechnungen
|
This class manages the setting values of the internal (kernel) settings of this application. More...
#include <settings.hpp>
Public Member Functions | |
Settings () | |
Settings class default constructor. Creates and fills the internal setting value map with their default values. More... | |
Settings (const Settings &_settings) | |
Settings class copy constructor. Delegates the initialization to the default constructor. More... | |
void | copySettings (const Settings &_settings) |
This member function is an alias for the assignment operator overload. More... | |
Settings & | operator= (const Settings &_settings) |
Assignment operator overload. More... | |
void | save (const std::string &_sWhere, bool bMkBackUp=false) |
Saves the setting values to the corresponding config file. Does only save the setting values, which are marked that they shall be saved. More... | |
void | load (const std::string &_sWhere) |
Opens the configuration file, identifies its version and imports the setting values. More... | |
SettingsValue & | getSetting (const std::string &value) |
Returns a reference to the setting value, which corresponds to the passed string. Throws an exception, if the setting does not exist. More... | |
const SettingsValue & | getSetting (const std::string &value) const |
Returns a const reference to the setting value, which corresponds to the passed string. Throws an exception, if the setting does not exist. More... | |
std::map< std::string, SettingsValue > & | getSettings () |
Returns a reference to the internal map of setting values. More... | |
const std::map< std::string, SettingsValue > & | getSettings () const |
Returns a const reference to the internal map of setting values. More... | |
void | enable (const std::string &option) |
Enables a setting with boolean value type. If the setting does not have this type, nothing happens. More... | |
void | disable (const std::string &option) |
Disables a setting with boolean value type. If the setting does not have this type, nothing happens. More... | |
bool | isEnabled (const std::string &option) const |
Returns true, if the setting with boolean value type is enabled, false otherwise. If the setting does not have a boolean value type, this method will return false as well. More... | |
void | enableSystemPrints (bool _bSystemPrints=true) |
Enables or disables the system printing functionality. This is a convenience wrapper for the direct map access. More... | |
void | setDefaultPlotFont (const std::string &plotFont) |
Update the default plotting font. This member function evaluates first, whether the selected font actually exists. More... | |
bool | isDeveloperMode () const |
Returns, whether the developer mode is currently enabled. More... | |
bool | isDraftMode () const |
Returns, whether the plotting draft mode is enabled. More... | |
bool | createCompactTables () const |
Returns, whether tables shall be displayed in a more compact way (does nothing in the external table viewer). More... | |
bool | showGreeting () const |
Returns, whether NumeRe shall greet the user with a funny message at application start-up. More... | |
bool | showHints () const |
Returns, whether the tip-of-the-day shall be displayed to the user at application start-up. More... | |
bool | useEscInScripts () const |
Returns, whether ESC key presses shall be handled, when scripts are being executed. More... | |
bool | controlDefinitions () const |
Returns, whether NumeRe shall load and save custom functions automatically. More... | |
bool | showExtendedFileInfo () const |
Returns, whether the file tree or the terminal file explorer shall display extended file information for NumeRe data files. More... | |
bool | useLogFile () const |
Returns, whether the terminal inputs shall be protocoled in a dedicated logfile. This setting does not modify the history functionality. More... | |
bool | loadEmptyCols () const |
Returns, whether NumeRe shall keep empty columns when loading a file to memory. More... | |
size_t | getPrecision () const |
Returns the precision for displaying floating numbers in the terminal. This value determines the number of valid numbers, which shall be displayed. More... | |
std::string | getExePath () const |
Returns the current application root folder path. More... | |
std::string | getWorkPath () const |
Returns the current working path (connected to the <wp> token). More... | |
std::string | getSavePath () const |
Returns the current saving path. More... | |
std::string | getLoadPath () const |
Returns the current loading path. More... | |
std::string | getPlotPath () const |
Returns the current plotting path (plot storing location). More... | |
std::string | getScriptPath () const |
Returns the current script import folder path. More... | |
std::string | getProcPath () const |
Returns the current procedure root import path. More... | |
size_t | getAutoSaveInterval () const |
Returns the timespan for the autosave interval in seconds. More... | |
size_t | getBuffer () const |
Returns the current terminal buffer size. More... | |
size_t | getWindow (int nWindow=0) const |
Returns the current window size of the terminal. More... | |
std::string | getDefaultPlotFont () const |
Returns the current plotting font name. More... | |
std::string | getTokenPaths () const |
Returns a semicolon-separated list of the current defined path placeholders and their values. More... | |
bool | systemPrints () const |
Returns, whether system messages shall be printed to the terminal. More... | |
bool | useDebugger () const |
Returns, whether the debugger is currently active. More... | |
bool | useCustomLangFiles () const |
Returns, whether user language files shall be used to override internal language strings. More... | |
bool | useExternalDocWindow () const |
Returns, whether documentations shall be displayed in external windows. More... | |
bool | executeEnabled () const |
Returns, whether the user enabled the execute command. More... | |
bool | useMaskDefault () const |
Returns, whether loop flow control statements shall use the mask option automatically. More... | |
bool | decodeArguments () const |
Returns, whether the debugger shall try to decode procedure arguments. More... | |
Public Member Functions inherited from Documentation | |
Documentation () | |
The default constructor. More... | |
~Documentation () | |
The destructor closes the internal file stream, if it is still open. More... | |
void | createDocumentationIndex (bool bLoadUserLangFiles=true) |
This member function loads the index files to memory. More... | |
void | addFileToDocumentationIndex (const std::string &sFileName) |
This member function is used to add documentation index entries to the index during a plugin or package installation. More... | |
void | removeFromDocIndex (const std::string &_sID) |
This member function removes the index entry passed to the function from the documentation index. More... | |
std::vector< std::string > | getHelpArticle (const std::string &sTopic) |
This member function returns the documentation article, which corresponds to the passed documentation topic of the the whole documentation index in readable form. More... | |
std::vector< std::string > | getDocIndex () const |
This member function returns the key list for the documentation index prepared for the corresponding tree in the documentation browser. More... | |
std::string | getHelpIdxKey (const std::string &sTopic) |
This member function returns an index key, which corresponds to the queried topic. More... | |
std::string | getHelpArticleID (const std::string &sTopic) |
This member function returns the article ID corresponding to the queried topic. More... | |
std::string | getHelpArticleTitle (const std::string &_sIdxKey) |
This member function returns the documentation article title corresponding to the queried index key. More... | |
Public Member Functions inherited from FileSystem | |
FileSystem () | |
Default constructor. More... | |
FileSystem & | assign (const FileSystem &_fSys) |
Assignment member function to copy the settings from another FileSystem instance. More... | |
std::string | ValidFileName (std::string _sFileName, const std::string sExtension=".dat", bool checkExtension=true, bool doCleanPath=true) const |
This member function evaluates, whether the passed filename is a valid filename. One may supply a preferred filename extension. More... | |
std::string | ValidFolderName (std::string _sFileName, bool doCleanPath=true, bool appendTrailingSeparator=true) const |
This member function evaluates, whether the passed foldername is a valid foldername. More... | |
std::string | ValidizeAndPrepareName (const std::string &_sFileName, const std::string &sExtension=".dat") const |
This member function validizes the passed file name and creates the needed folders on-the-fly. More... | |
int | setPath (std::string _sPath, bool bMkDir, std::string _sExePath) |
This member function may be used to set the preferred file path of the current FileSystem instance. More... | |
void | createRevisionsFolder () |
This member function creates the hidden revisions folders for the version control system. More... | |
std::string | getPath () const |
Returns the default path of this FileSystem instance. More... | |
std::vector< std::string > | getFileParts (const std::string &sFilePath) const |
This member function separates all path parts into single strings: the drive letter, the path, the name and the extension. This function may also handle folder paths and network paths. More... | |
FileInfo | getFileInfo (const std::string &sFilePath) const |
Return the file information about the passed file path. More... | |
void | setTokens (std::string _sTokens) |
This member function may be used to update the path placeholders of the current FileSystem instance. More... | |
bool | isFile (const std::string &_sPath) const |
This function determines, whether a path name indicates a file or a folder. More... | |
void | initializeFromKernel () |
Member function to remote-initialize the class from the kernel. Cannot be used during kernel start-up. More... | |
void | setProgramPath (std::string _sExePath) |
std::string | getProgramPath () const |
void | declareFileType (const std::string &sFileType) |
Protected Attributes | |
std::map< std::string, SettingsValue > | m_settings |
Protected Attributes inherited from FileSystem | |
std::string | sPath |
std::string | sExecutablePath |
std::string | sTokens [7][2] |
std::string | sValidExtensions |
Private Member Functions | |
void | import_v1x (const std::string &sSettings) |
Imports a setting value string from a v1.x configuration file. More... | |
bool | set (const std::string &) |
Imports a setting value from a v0.9x configuration file. More... | |
std::string | replaceExePath (const std::string &_sPath) |
This member function is a helper, which will replace the executable path part in the passed file path with the <> path token. More... | |
void | prepareFilePaths (const std::string &_sExePath) |
This member function is a helper, which will replace the <> path token in all default file paths with the corresponding executable path. More... | |
Private Attributes | |
std::string | sSettings_ini |
Additional Inherited Members | |
Static Public Member Functions inherited from Documentation | |
static std::string | getArgAtPos (const std::string &sCmd, unsigned int pos) |
This static member is a fallback for the XML-parsing logic-stuff. More... | |
Protected Member Functions inherited from FileSystem | |
int | createFolders (const std::string &_sPath) const |
This member function creates all missing directories in the passed path. More... | |
This class manages the setting values of the internal (kernel) settings of this application.
Definition at line 662 of file settings.hpp.
Settings::Settings | ( | ) |
Settings class default constructor. Creates and fills the internal setting value map with their default values.
Definition at line 39 of file settings.cpp.
References DEFAULT_ST_ACTIVELINE, DEFAULT_ST_CLUSTER, DEFAULT_ST_COMMAND, DEFAULT_ST_COMMENT, DEFAULT_ST_CONSOLESTD, DEFAULT_ST_CONSTANT, DEFAULT_ST_CUSTOMFUNC, DEFAULT_ST_DEFVARS, DEFAULT_ST_DOCCOMMENT, DEFAULT_ST_DOCKEYWORD, DEFAULT_ST_FUNCTION, DEFAULT_ST_INCLUDES, DEFAULT_ST_INSTALL, DEFAULT_ST_METHODS, DEFAULT_ST_NUMBER, DEFAULT_ST_OPERATOR, DEFAULT_ST_OPTION, DEFAULT_ST_PROCCOMMAND, DEFAULT_ST_PROCEDURE, DEFAULT_ST_SPECIALVAL, DEFAULT_ST_STANDARD, DEFAULT_ST_STRING, DEFAULT_ST_STRINGPARSER, SettingsValue::HIDDEN, SettingsValue::IMMUTABLE, m_settings, SettingsValue::NONE, SettingsValue::PATH, SettingsValue::SAVE, SETTING_B_AN_ALWAYSMETRICS, SETTING_B_AN_COMMENTDENS, SETTING_B_AN_COMPLEXITY, SETTING_B_AN_CONSTANTS, SETTING_B_AN_FALLTHROUGH, SETTING_B_AN_GLOBALVARS, SETTING_B_AN_INLINEIF, SETTING_B_AN_LOC, SETTING_B_AN_MAGICNUMBERS, SETTING_B_AN_MISLEADINGTYPE, SETTING_B_AN_PROCLENGTH, SETTING_B_AN_PROGRESS, SETTING_B_AN_RESULTASS, SETTING_B_AN_RESULTSUP, SETTING_B_AN_START, SETTING_B_AN_THISFILE, SETTING_B_AN_TYPING, SETTING_B_AN_UNDERSCOREARGS, SETTING_B_AN_UNUSEDVARS, SETTING_B_AN_USEERRORS, SETTING_B_AN_USENOTES, SETTING_B_AN_USEWARNINGS, SETTING_B_AN_VARLENGTH, SETTING_B_AUTOSAVEEXECUTION, SETTING_B_BLOCKAUTOCOMP, SETTING_B_BRACEAUTOCOMP, SETTING_B_COMPACT, SETTING_B_DEBUGGER, SETTING_B_DECODEARGUMENTS, SETTING_B_DEFCONTROL, SETTING_B_DEVELOPERMODE, SETTING_B_DRAFTMODE, SETTING_B_ENABLEEXECUTE, SETTING_B_EXTENDEDFILEINFO, SETTING_B_EXTERNALDOCWINDOW, SETTING_B_FLASHTASKBAR, SETTING_B_FOLDLOADEDFILE, SETTING_B_FORMATBEFORESAVING, SETTING_B_GLOBALVARS, SETTING_B_GREETING, SETTING_B_HIGHLIGHTLOCALS, SETTING_B_HOMEENDCANCELS, SETTING_B_ICONSONTABS, SETTING_B_LINELENGTH, SETTING_B_LINESINSTACK, SETTING_B_LOADEMPTYCOLS, SETTING_B_LOGFILE, SETTING_B_MASKDEFAULT, SETTING_B_MODULESINSTACK, SETTING_B_PATHSONTABS, SETTING_B_PRINTINCOLOR, SETTING_B_PRINTLINENUMBERS, SETTING_B_PROCEDUREARGS, SETTING_B_QUOTEAUTOCOMP, SETTING_B_SAVEBOOKMARKS, SETTING_B_SAVESASHS, SETTING_B_SAVESESSION, SETTING_B_SAVEWINDOWSIZE, SETTING_B_SHOWHINTS, SETTING_B_SMARTSENSE, SETTING_B_SYSTEMPRINTS, SETTING_B_TABLEREFS, SETTING_B_TOOLBARTEXT, SETTING_B_USECUSTOMLANG, SETTING_B_USEESCINSCRIPTS, SETTING_B_USEREVISIONS, SETTING_B_USETABS, SETTING_S_EDITORFONT, SETTING_S_EXEPATH, SETTING_S_HISTORYFONT, SETTING_S_LATEXROOT, SETTING_S_LOADPATH, SETTING_S_PLOTFONT, SETTING_S_PLOTPATH, SETTING_S_PROCPATH, SETTING_S_SAVEPATH, SETTING_S_SCRIPTPATH, SETTING_S_ST_ACTIVELINE, SETTING_S_ST_CLUSTER, SETTING_S_ST_COMMAND, SETTING_S_ST_COMMENT, SETTING_S_ST_CONSOLESTD, SETTING_S_ST_CONSTANT, SETTING_S_ST_CUSTOMFUNC, SETTING_S_ST_DEFVARS, SETTING_S_ST_DOCCOMMENT, SETTING_S_ST_DOCKEYWORD, SETTING_S_ST_FUNCTION, SETTING_S_ST_INCLUDES, SETTING_S_ST_INSTALL, SETTING_S_ST_METHODS, SETTING_S_ST_NUMBER, SETTING_S_ST_OPERATOR, SETTING_S_ST_OPTION, SETTING_S_ST_PROCCOMMAND, SETTING_S_ST_PROCEDURE, SETTING_S_ST_SPECIALVAL, SETTING_S_ST_STANDARD, SETTING_S_ST_START, SETTING_S_ST_STRING, SETTING_S_ST_STRINGPARSER, SETTING_S_TERMINALFONT, SETTING_S_WINDOWSIZE, SETTING_S_WORKPATH, SETTING_V_AUTOSAVE, SETTING_V_BUFFERSIZE, SETTING_V_CARETBLINKTIME, SETTING_V_FOCUSEDLINE, SETTING_V_POS_SASH_H, SETTING_V_POS_SASH_T, SETTING_V_POS_SASH_V, SETTING_V_PRECISION, SETTING_V_WINDOW_X, SETTING_V_WINDOW_Y, sSettings_ini, and SettingsValue::UIREFRESH.
Settings::Settings | ( | const Settings & | _settings | ) |
Settings class copy constructor. Delegates the initialization to the default constructor.
_settings | const Settings& |
Definition at line 170 of file settings.cpp.
References copySettings().
|
inline |
Returns, whether NumeRe shall load and save custom functions automatically.
Definition at line 955 of file settings.hpp.
References m_settings, and SETTING_B_DEFCONTROL.
Referenced by NumeReKernel::CloseSession(), and NumeReKernel::StartUp().
void Settings::copySettings | ( | const Settings & | _settings | ) |
This member function is an alias for the assignment operator overload.
_settings | const Settings& |
Definition at line 740 of file settings.cpp.
References getTokenPaths(), m_settings, and FileSystem::setTokens().
Referenced by NumeReWindow::OnClose(), NumeReWindow::OnOptions(), NumeReTerminal::OnThreadUpdate(), operator=(), NumeReKernel::setKernelSettings(), and Settings().
|
inline |
Returns, whether tables shall be displayed in a more compact way (does nothing in the external table viewer).
Definition at line 913 of file settings.hpp.
References m_settings, and SETTING_B_COMPACT.
Referenced by cmd_show(), createOutputForHist1D(), and createOutputForHist2D().
|
inline |
Returns, whether the debugger shall try to decode procedure arguments.
Definition at line 1202 of file settings.hpp.
References m_settings, and SETTING_B_DECODEARGUMENTS.
|
inline |
Disables a setting with boolean value type. If the setting does not have this type, nothing happens.
option | const std::string& |
Definition at line 791 of file settings.hpp.
References SettingsValue::BOOL, and m_settings.
|
inline |
Enables a setting with boolean value type. If the setting does not have this type, nothing happens.
option | const std::string& |
Definition at line 774 of file settings.hpp.
References SettingsValue::BOOL, and m_settings.
|
inline |
Enables or disables the system printing functionality. This is a convenience wrapper for the direct map access.
_bSystemPrints | bool |
Definition at line 829 of file settings.hpp.
References m_settings, and SETTING_B_SYSTEMPRINTS.
Referenced by Procedure::execute(), NumeReKernel::executePlugins(), NumeReKernel::MainLoop(), and Procedure::procedureInterface().
|
inline |
Returns, whether the user enabled the execute
command.
Definition at line 1181 of file settings.hpp.
References m_settings, and SETTING_B_ENABLEEXECUTE.
Referenced by executeCommand().
|
inline |
Returns the timespan for the autosave interval in seconds.
Definition at line 1078 of file settings.hpp.
References m_settings, and SETTING_V_AUTOSAVE.
Referenced by NumeReKernel::getAutosaveInterval().
|
inline |
Returns the current terminal buffer size.
Definition at line 1088 of file settings.hpp.
References m_settings, and SETTING_V_BUFFERSIZE.
|
inline |
Returns the current plotting font name.
Definition at line 1111 of file settings.hpp.
References m_settings, and SETTING_S_PLOTFONT.
Referenced by PlotData::reset(), and NumeReKernel::StartUp().
|
inline |
Returns the current application root folder path.
Definition at line 1010 of file settings.hpp.
References m_settings, and SETTING_S_EXEPATH.
Referenced by applySyntaxHighlighting(), clear_cache(), NumeReKernel::CloseSession(), cmd_define(), cmd_save(), cmd_set(), doc_ReplaceTokensForHTML(), doc_SearchFct(), editObject(), executeCommand(), extractFirstParameterStringValue(), NumeReKernel::getPathSettings(), initializeFileHandle(), listDirectory(), listFiles(), newObject(), NumeRe::StringParser::numToString(), NumeReKernel::printVersionInfo(), saveDataObject(), NumeReKernel::StartUp(), and strfnc_findfile().
|
inline |
Returns the current loading path.
Definition at line 1038 of file settings.hpp.
References m_settings, and SETTING_S_LOADPATH.
Referenced by doc_ReplaceTokensForHTML(), editObject(), NumeReKernel::getPathSettings(), initializeFileHandle(), listDirectory(), listFiles(), NumeRe::StringParser::numToString(), and NumeReKernel::StartUp().
|
inline |
Returns the current plotting path (plot storing location).
Definition at line 1048 of file settings.hpp.
References m_settings, and SETTING_S_PLOTPATH.
Referenced by doc_ReplaceTokensForHTML(), editObject(), NumeReKernel::getPathSettings(), initializeFileHandle(), listDirectory(), listFiles(), NumeRe::StringParser::numToString(), and NumeReKernel::StartUp().
|
inline |
Returns the precision for displaying floating numbers in the terminal. This value determines the number of valid numbers, which shall be displayed.
Definition at line 1000 of file settings.hpp.
References m_settings, and SETTING_V_PRECISION.
Referenced by cmd_show(), cmd_warn(), FunctionDefinition::convertToValues(), createStatsFile(), NumeRe::StringParser::createTerminalOutput(), evaluateParameterValues(), findExtrema(), formatNumberToTex(), NumeReKernel::formatResultOutput(), getParameterTable(), PlotData::getParams(), getVarList(), listConstants(), listDeclaredVariables(), NumeReKernel::numberOfNumbersPerLine(), parseArg(), saveDataObject(), showMatrixResult(), NumeRe::StringParser::storeStringResults(), taylor(), and toString().
|
inline |
Returns the current procedure root import path.
Definition at line 1068 of file settings.hpp.
References m_settings, and SETTING_S_PROCPATH.
Referenced by Dependencies::Dependencies(), doc_ReplaceTokensForHTML(), editObject(), NumeReKernel::getPathSettings(), NumeRe::CallTipProvider::getProcedure(), initializeFileHandle(), listDirectory(), listFiles(), NumeReKernel::MainLoop(), NumeRe::StringParser::numToString(), parseEventOpt(), and NumeReKernel::StartUp().
|
inline |
Returns the current saving path.
Definition at line 1029 of file settings.hpp.
References m_settings, and SETTING_S_SAVEPATH.
Referenced by clear_cache(), doc_ReplaceTokensForHTML(), editObject(), NumeReKernel::getPathSettings(), initializeFileHandle(), listDirectory(), listFiles(), NumeRe::StringParser::numToString(), saveDataObject(), and NumeReKernel::StartUp().
|
inline |
Returns the current script import folder path.
Definition at line 1058 of file settings.hpp.
References m_settings, and SETTING_S_SCRIPTPATH.
Referenced by doc_ReplaceTokensForHTML(), editObject(), NumeReKernel::getPathSettings(), initializeFileHandle(), listDirectory(), listFiles(), NumeRe::StringParser::numToString(), and NumeReKernel::StartUp().
|
inline |
Returns a reference to the setting value, which corresponds to the passed string. Throws an exception, if the setting does not exist.
value | const std::string& |
Definition at line 711 of file settings.hpp.
References SyntaxError::INVALID_SETTING, and m_settings.
Referenced by CodeAnalyzer::analyseIdentifiers(), NumeReKernel::CloseSession(), cmd_workpath(), createCssString(), NumeReWindow::EvaluateOptions(), ProcedureVarFactory::evaluateProcedureArguments(), NumeReEditor::generateAutoCompList(), NumeReWindow::HandleModifiedFile(), NumeReKernel::MainLoop(), NumeReWindow::NumeReWindow(), NumeReEditor::OnAutoCompletion(), NumeReEditor::OnChar(), NumeReWindow::OnClose(), NumeReWindow::OnExecuteFile(), MyApp::OnInit(), NumeReWindow::OnMenuEvent(), NumeReWindow::OnOptions(), DebugViewer::setDebugInfo(), NumeReTerminal::setKernelSettings(), NumeReKernel::StartUp(), NumeReWindow::toggleConsole(), NumeReWindow::toggleFiletree(), NumeReWindow::toggleHistory(), NumeReEditor::updateDefaultHighlightSettings(), NumeReKernel::updateLineLenght(), NumeReHistory::UpdateSyntaxHighlighting(), NumeReWindow::UpdateTerminalNotebook(), and NumeReWindow::updateTipAtStartupSetting().
|
inline |
Returns a const reference to the setting value, which corresponds to the passed string. Throws an exception, if the setting does not exist.
value | const std::string& |
Definition at line 731 of file settings.hpp.
References SyntaxError::INVALID_SETTING, and m_settings.
|
inline |
Returns a reference to the internal map of setting values.
Definition at line 748 of file settings.hpp.
References m_settings.
Referenced by cmd_get(), cmd_set(), OptionsDialog::EvaluateOptions(), OptionsDialog::InitializeDialog(), and NumeReWindow::InitializeProgramOptions().
|
inline |
Returns a const reference to the internal map of setting values.
Definition at line 760 of file settings.hpp.
References m_settings.
|
inline |
Returns a semicolon-separated list of the current defined path placeholders and their values.
Definition at line 1122 of file settings.hpp.
References m_settings, SETTING_S_EXEPATH, SETTING_S_LOADPATH, SETTING_S_PLOTPATH, SETTING_S_PROCPATH, SETTING_S_SAVEPATH, SETTING_S_SCRIPTPATH, and SETTING_S_WORKPATH.
Referenced by cmd_set(), copySettings(), editObject(), executeCommand(), extractFirstParameterStringValue(), saveDataObject(), NumeReKernel::StartUp(), and strfnc_findfile().
|
inline |
Returns the current window size of the terminal.
nWindow | int |
Definition at line 1101 of file settings.hpp.
References m_settings, SETTING_V_WINDOW_X, and SETTING_V_WINDOW_Y.
Referenced by fitDataSet(), Output::format(), formatMatrixRow(), LineBreak(), listConstants(), listDeclaredVariables(), listDirectory(), listFiles(), listInstalledPlugins(), listUnitConversions(), showMatrixResult(), and NumeReKernel::StartUp().
|
inline |
Returns the current working path (connected to the <wp> token).
Definition at line 1020 of file settings.hpp.
References m_settings, and SETTING_S_WORKPATH.
Referenced by editObject(), NumeReKernel::getPathSettings(), initializeFileHandle(), listDirectory(), listFiles(), and NumeRe::StringParser::numToString().
|
private |
Imports a setting value string from a v1.x configuration file.
sSettings | const std::string& |
Definition at line 267 of file settings.cpp.
References SettingsValue::BOOL, m_settings, SettingsValue::STRING, StrToInt(), SettingsValue::TYPELESS, and SettingsValue::UINT.
Referenced by load().
|
inline |
Returns, whether the developer mode is currently enabled.
Definition at line 892 of file settings.hpp.
References m_settings, and SETTING_B_DEVELOPERMODE.
Referenced by cmd_set(), and make_stringmatrix().
|
inline |
Returns, whether the plotting draft mode is enabled.
Definition at line 902 of file settings.hpp.
References m_settings, and SETTING_B_DRAFTMODE.
Referenced by Plot::create3dPlot(), Plot::displayMessage(), and Plot::plot2d().
|
inline |
Returns true, if the setting with boolean value type is enabled, false otherwise. If the setting does not have a boolean value type, this method will return false as well.
option | const std::string& |
Definition at line 810 of file settings.hpp.
References SettingsValue::BOOL, and m_settings.
Referenced by NumeReWindow::EvaluateOptions(), and NumeReEditor::OnKeyDn().
void Settings::load | ( | const std::string & | _sWhere | ) |
Opens the configuration file, identifies its version and imports the setting values.
_sWhere | const std::string& |
Definition at line 607 of file settings.cpp.
References import_v1x(), m_settings, prepareFilePaths(), NumeReKernel::printPreFmt(), save(), set(), SETTING_B_COMPACT, SETTING_S_LOADPATH, SETTING_S_PLOTPATH, SETTING_S_SAVEPATH, SETTING_V_AUTOSAVE, SETTING_V_PRECISION, FileSystem::sExecutablePath, sSettings_ini, and StrToInt().
Referenced by NumeReKernel::StartUp().
|
inline |
Returns, whether NumeRe shall keep empty columns when loading a file to memory.
Definition at line 988 of file settings.hpp.
References m_settings, and SETTING_B_LOADEMPTYCOLS.
Referenced by NumeReKernel::StartUp().
Assignment operator overload.
_settings | const Settings& |
Definition at line 691 of file settings.hpp.
References copySettings().
|
private |
This member function is a helper, which will replace the <> path token in all default file paths with the corresponding executable path.
_sExePath | const std::string& |
Definition at line 574 of file settings.cpp.
References m_settings, SETTING_S_EXEPATH, SETTING_S_LOADPATH, SETTING_S_PLOTPATH, SETTING_S_PROCPATH, SETTING_S_SAVEPATH, SETTING_S_SCRIPTPATH, and SETTING_S_WORKPATH.
Referenced by load().
|
private |
This member function is a helper, which will replace the executable path part in the passed file path with the <> path token.
_sPath | const std::string& |
Definition at line 552 of file settings.cpp.
References m_settings, SETTING_S_EXEPATH, and FileSystem::sPath.
Referenced by save().
void Settings::save | ( | const std::string & | _sWhere, |
bool | bMkBackUp = false |
||
) |
Saves the setting values to the corresponding config file. Does only save the setting values, which are marked that they shall be saved.
_sWhere | const std::string& |
bMkBackUp | bool |
Definition at line 187 of file settings.cpp.
References _lang, SettingsValue::BOOL, Language::get(), m_settings, NumeReKernel::print(), replaceExePath(), FileSystem::sExecutablePath, sSettings_ini, SettingsValue::STRING, toSystemCodePage(), date::detail::trunc(), SettingsValue::TYPELESS, and SettingsValue::UINT.
Referenced by NumeReKernel::CloseSession(), cmd_save(), cmd_set(), load(), and Options::SetSaveBookmarksInSession().
|
private |
Imports a setting value from a v0.9x configuration file.
_sOption | const std::string& |
Definition at line 306 of file settings.cpp.
References findParameter(), m_settings, SETTING_B_COMPACT, SETTING_B_DECODEARGUMENTS, SETTING_B_DEFCONTROL, SETTING_B_DRAFTMODE, SETTING_B_ENABLEEXECUTE, SETTING_B_EXTENDEDFILEINFO, SETTING_B_EXTERNALDOCWINDOW, SETTING_B_GREETING, SETTING_B_LOADEMPTYCOLS, SETTING_B_LOGFILE, SETTING_B_MASKDEFAULT, SETTING_B_SHOWHINTS, SETTING_B_USECUSTOMLANG, SETTING_B_USEESCINSCRIPTS, SETTING_S_LOADPATH, SETTING_S_PLOTFONT, SETTING_S_PLOTPATH, SETTING_S_PROCPATH, SETTING_S_SAVEPATH, SETTING_S_SCRIPTPATH, SETTING_V_AUTOSAVE, SETTING_V_BUFFERSIZE, SETTING_V_PRECISION, SETTING_V_WINDOW_X, SETTING_V_WINDOW_Y, StripSpaces(), and StrToInt().
Referenced by load().
|
inline |
Update the default plotting font. This member function evaluates first, whether the selected font actually exists.
plotFont | const std::string& |
Definition at line 843 of file settings.hpp.
References m_settings, and SETTING_S_PLOTFONT.
Referenced by cmd_set().
|
inline |
Returns, whether the file tree or the terminal file explorer shall display extended file information for NumeRe data files.
Definition at line 966 of file settings.hpp.
References m_settings, and SETTING_B_EXTENDEDFILEINFO.
Referenced by NumeReWindow::getFileDetails(), and listDirectory().
|
inline |
Returns, whether NumeRe shall greet the user with a funny message at application start-up.
Definition at line 924 of file settings.hpp.
References m_settings, and SETTING_B_GREETING.
Referenced by NumeReKernel::printVersionInfo().
|
inline |
Returns, whether the tip-of-the-day shall be displayed to the user at application start-up.
Definition at line 935 of file settings.hpp.
References m_settings, and SETTING_B_SHOWHINTS.
Referenced by NumeReWindow::NumeReWindow().
|
inline |
Returns, whether system messages shall be printed to the terminal.
Definition at line 1140 of file settings.hpp.
References m_settings, and SETTING_B_SYSTEMPRINTS.
Referenced by append_data(), applyFitAlgorithm(), autoSave(), calculateChiMap(), calculateSplines(), clear_cache(), cmd_clear(), cmd_copy(), cmd_datagrid(), cmd_define(), cmd_delete(), cmd_ifndefined(), cmd_load(), cmd_move(), cmd_plotting(), cmd_redefine(), cmd_regularize(), cmd_remove(), cmd_rename(), cmd_resample(), cmd_retouch(), cmd_set(), cmd_smooth(), cmd_workpath(), createHist2D(), createOutputForHist1D(), createPlotForHist1D(), Plot::createPlotOrAnimation(), createPlotsForHist2D(), Plot::createSubPlotSet(), Plot::displayMessage(), FlowCtrl::eval(), Procedure::execute(), executeCommand(), fastFourierTransform(), fastWaveletTransform(), fitDataSet(), Output::format(), integrate(), integrate2d(), FunctionDefinitionManager::load(), newObject(), Plot::Plot(), Procedure::procedureInterface(), FunctionDefinitionManager::save(), saveDataObject(), showMatrixResult(), Odesolver::solve(), solveLGSSymbolic(), swapTables(), taylor(), and undefineFunctions().
|
inline |
Returns, whether user language files shall be used to override internal language strings.
Definition at line 1161 of file settings.hpp.
References m_settings, and SETTING_B_USECUSTOMLANG.
Referenced by NumeReWindow::DefaultPage(), doc_SearchFct(), NumeReKernel::getGreeting(), NumeReEditor::getTemplateContent(), NumeReWindow::NewFile(), NumeReWindow::NumeReWindow(), NumeReWindow::refreshFunctionTree(), NumeReKernel::StartUp(), and NumeReWindow::UpdateToolbar().
|
inline |
Returns, whether the debugger is currently active.
Definition at line 1150 of file settings.hpp.
References m_settings, and SETTING_B_DEBUGGER.
Referenced by FlowCtrl::calc(), cmd_set(), FlowCtrl::compile(), ProcedureVarFactory::createProcedureArguments(), FlowCtrl::evalHeader(), FlowCtrl::evalRangeBasedHeader(), Procedure::execute(), FlowCtrl::for_loop(), FlowCtrl::if_fork(), NumeReKernel::MainLoop(), NumeReWindow::OnMenuEvent(), FlowCtrl::range_based_for_loop(), NumeReKernel::setKernelSettings(), FlowCtrl::switch_fork(), FlowCtrl::try_catch(), NumeReWindow::UpdateMenuBar(), NumeReWindow::UpdateStatusBar(), NumeReWindow::UpdateToolbar(), and FlowCtrl::while_loop().
|
inline |
Returns, whether ESC key presses shall be handled, when scripts are being executed.
Definition at line 945 of file settings.hpp.
References m_settings, and SETTING_B_USEESCINSCRIPTS.
Referenced by NumeReKernel::MainLoop().
|
inline |
Returns, whether documentations shall be displayed in external windows.
Definition at line 1171 of file settings.hpp.
References m_settings, and SETTING_B_EXTERNALDOCWINDOW.
Referenced by make_stringmatrix(), and show_data().
|
inline |
Returns, whether the terminal inputs shall be protocoled in a dedicated logfile. This setting does not modify the history functionality.
Definition at line 978 of file settings.hpp.
References m_settings, and SETTING_B_LOGFILE.
Referenced by NumeReKernel::StartUp().
|
inline |
Returns, whether loop flow control statements shall use the mask
option automatically.
Definition at line 1192 of file settings.hpp.
References m_settings, and SETTING_B_MASKDEFAULT.
Referenced by FlowCtrl::eval().
|
protected |
Definition at line 676 of file settings.hpp.
Referenced by controlDefinitions(), copySettings(), createCompactTables(), decodeArguments(), disable(), enable(), enableSystemPrints(), executeEnabled(), Options::GetAnalyzerOption(), getAutoSaveInterval(), getBuffer(), Options::GetCaretBlinkTime(), Options::GetDebuggerFocusLine(), getDefaultPlotFont(), Options::GetEditorFont(), getExePath(), Options::GetFoldDuringLoading(), Options::GetFormatBeforeSaving(), Options::GetHighlightLocalVariables(), Options::GetKeepBackupFile(), Options::GetLaTeXRoot(), Options::GetLineNumberPrinting(), getLoadPath(), getPlotPath(), getPrecision(), Options::GetPrintStyle(), getProcPath(), Options::GetSaveBookmarksInSession(), getSavePath(), Options::GetSaveSession(), getScriptPath(), getSetting(), getSettings(), Options::GetShowGlobalVariables(), Options::GetShowLinesInStackTrace(), Options::GetShowModulesInStackTrace(), Options::GetShowPathOnTabs(), Options::GetShowProcedureArguments(), Options::GetShowToolbarText(), Options::GetSyntaxStyle(), Options::GetTerminalHistorySize(), getTokenPaths(), getWindow(), getWorkPath(), import_v1x(), isDeveloperMode(), isDraftMode(), isEnabled(), load(), loadEmptyCols(), prepareFilePaths(), Options::readColoursFromConfig(), replaceExePath(), save(), set(), Options::SetAnalyzerOption(), Options::SetCaretBlinkTime(), Options::SetDebuggerFocusLine(), setDefaultPlotFont(), Options::SetEditorFont(), Options::SetFoldDuringLoading(), Options::SetFormatBeforeSaving(), Options::SetHighlightLocalVariables(), Options::SetKeepBackupFile(), Options::SetLaTeXRoot(), Options::SetLineNumberPrinting(), Options::SetPrintStyle(), Options::SetSaveBookmarksInSession(), Options::SetSaveSession(), Options::SetShowGlobalVariables(), Options::SetShowLinesInStackTrace(), Options::SetShowModulesInStackTrace(), Options::SetShowPathOnTabs(), Options::SetShowProcedureArguments(), Options::SetShowToolbarText(), Options::SetSyntaxStyle(), Options::SetTerminalHistorySize(), Settings(), showExtendedFileInfo(), showGreeting(), showHints(), systemPrints(), useCustomLangFiles(), useDebugger(), useEscInScripts(), useExternalDocWindow(), useLogFile(), and useMaskDefault().
|
private |
Definition at line 665 of file settings.hpp.
Referenced by load(), save(), and Settings().