Settings
Central storage of application and user settings
- xl.settings.MANAGER
Singleton instance of the
SettingsManager
- xl.settings.get_option(name, default)
- xl.settings.set_option(option, value, save=True)
Set an option (in
section/keysyntax) to the specified value- Parameters:
option (string) – the full path to an option
value (any) – the value the option should be assigned
save – If True, cause the settings to be written to file
- class xl.settings.SettingsManager(location=None, default_location=None)[source]
Bases:
RawConfigParserManages Exaile’s settings
- get_option(option: str, default: Any = None) Any[source]
Get the value of an option (in
section/keysyntax), returning default if the key does not exist yet- Parameters:
option – the full path to an option
default – a default value to use as fallback
- Returns:
the option value or default
- has_option(option)[source]
Returns information about the existence of a particular option
- Parameters:
option (string) – the option path
- Returns:
whether the option exists or not
- Return type: