31 from python_qt_binding.QtCore
import QObject, Slot
35 """Storage of key-value data with a QSettings-like interface.""" 39 self.setObjectName(
'Settings')
50 @Slot(result=
'QStringList')
52 return self._settings_proxy.all_keys(self.
_group)
58 @Slot(result=
'QStringList')
60 return self._settings_proxy.child_groups(self.
_group)
62 @Slot(result=
'QStringList')
64 return self._settings_proxy.child_keys(self.
_group)
66 @Slot(str, result=bool)
68 return self._settings_proxy.contains(self.
_group, key)
74 self._settings_proxy.remove(self.
_group, key)
78 @Slot(str,
'QVariant')
82 value =
'__NoneType__' 83 self._settings_proxy.set_value(self.
_group, key, value)
85 @Slot(str,
'QVariant', result=
'QVariant')
86 def value(self, key, default_value=None):
88 if default_value
is None:
89 default_value =
'__NoneType__' 90 value = self._settings_proxy.value(self.
_group, key, default_value)
91 if value ==
'__NoneType__':
def get_settings(self, group)
def set_value(self, key, value)
def __init__(self, settings_proxy, group)
def value(self, key, default_value=None)