def load_settings(self): """Load default settings into the form""" for name, widget in self.form.widgets.items(): value = get_default_setting(name) self.form.set_widget_value(widget, value)
def reset_defaults(self): """Resets all settings to their deafult values""" for name, widget in self.form.widgets.items(): value = get_default_setting(name) self.form.set_widget_value(widget, value)
def load_settings(self): """Loads all settings from QSettings into the form""" for name, widget in self.form.widgets.items(): value = get_setting(name) if has_setting(name) \ else get_default_setting(name) self.form.set_widget_value(widget, value)