MCPcopy Index your code
hub / github.com/PySimpleGUI/PySimpleGUI / user_settings_load

Function user_settings_load

PySimpleGUI/PySimpleGUI.py:23045–23059  ·  view source on GitHub ↗

Specifies the path and filename to use for the settings and reads the contents of the file. The filename can be a full filename including a path, or the path can be specified separately. If no filename is specified, then the caller's filename will be used with the extension ".json"

(filename=None, path=None)

Source from the content-addressed store, hash-verified

23043
23044
23045def user_settings_load(filename=None, path=None):
23046 """
23047 Specifies the path and filename to use for the settings and reads the contents of the file.
23048 The filename can be a full filename including a path, or the path can be specified separately.
23049 If no filename is specified, then the caller's filename will be used with the extension ".json"
23050
23051 :param filename: Filename to load settings from (and save to in the future)
23052 :type filename: (str)
23053 :param path: Path to the file. Defaults to a specific folder depending on the operating system
23054 :type path: (str)
23055 :return: The settings dictionary (i.e. all settings)
23056 :rtype: (dict)
23057 """
23058 settings = UserSettings._default_for_function_interface
23059 return settings.load(filename, path)
23060
23061
23062def user_settings_file_exists(filename=None, path=None):

Callers

nothing calls this directly

Calls 1

loadMethod · 0.80

Tested by

no test coverage detected