From bed6292dde5c9a017a7cac7be6948471949174e8 Mon Sep 17 00:00:00 2001 From: Andy Shaw Date: Thu, 7 Dec 2017 14:49:44 +0100 Subject: Win: Document limitation regarding registry types not being preserved QSettings does not preserve the original key type in the registry, it will set the type for the key based on the value that is being set. Therefore we should make it clear that existing key types will be overridden as this can cause some problems with types we do not directly support (such as REG_EXPAND_SZ). Task-number: QTBUG-2894 Change-Id: Ib2f2eed02759591e69fefb98a4a1f3cf897dd5cb Reviewed-by: Oswald Buddenhagen --- src/corelib/io/qsettings.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/corelib/io/qsettings.cpp') diff --git a/src/corelib/io/qsettings.cpp b/src/corelib/io/qsettings.cpp index d5460238ec..9b930e7e14 100644 --- a/src/corelib/io/qsettings.cpp +++ b/src/corelib/io/qsettings.cpp @@ -2358,6 +2358,11 @@ void QConfFileSettingsPrivate::ensureSectionParsed(QConfFile *confFile, limitations is to store the settings using the IniFormat instead of the NativeFormat. + \li On Windows, when the Windows system registry is used, QSettings + does not preserve the original type of the value. Therefore, + the type of the value might change when a new value is set. For + example, a value with type \c REG_EXPAND_SZ will change to \c REG_SZ. + \li On \macos and iOS, allKeys() will return some extra keys for global settings that apply to all applications. These keys can be read using value() but cannot be changed, only shadowed. -- cgit v1.2.3