From ff68be114e3db8bf1d2fa1fd0153862a25bf5e8b Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 16 Aug 2016 11:30:49 +0200 Subject: Fix documentation of the Windows parts of QSettings::setPath() MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Explain in terms of CSIDL_ values and update the sample locations. Task-number: QTBUG-55065 Change-Id: I15ddf32555d43cffae66d98c6ac12d62a98d5e6d Reviewed-by: Maurice Kalinowski Reviewed-by: Leena Miettinen Reviewed-by: Topi Reiniƶ --- src/corelib/io/qsettings.cpp | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'src/corelib/io') diff --git a/src/corelib/io/qsettings.cpp b/src/corelib/io/qsettings.cpp index 64a7b9529b..9e0e6c2769 100644 --- a/src/corelib/io/qsettings.cpp +++ b/src/corelib/io/qsettings.cpp @@ -2270,16 +2270,20 @@ void QConfFileSettingsPrivate::ensureSectionParsed(QConfFile *confFile, On Windows, the following files are used: \list 1 - \li \c{%APPDATA%\MySoft\Star Runner.ini} - \li \c{%APPDATA%\MySoft.ini} - \li \c{%COMMON_APPDATA%\MySoft\Star Runner.ini} - \li \c{%COMMON_APPDATA%\MySoft.ini} + \li \c{CSIDL_APPDATA\MySoft\Star Runner.ini} + \li \c{CSIDL_APPDATA\MySoft.ini} + \li \c{CSIDL_COMMON_APPDATA\MySoft\Star Runner.ini} + \li \c{CSIDL_COMMON_APPDATA\MySoft.ini} \endlist - The \c %APPDATA% path is usually \tt{C:\\Documents and - Settings\\\e{User Name}\\Application Data}; the \c - %COMMON_APPDATA% path is usually \tt{C:\\Documents and - Settings\\All Users\\Application Data}. + The identifiers prefixed by \c{CSIDL_} are special item ID lists to be passed + to the Win32 API function \c{SHGetSpecialFolderPath()} to obtain the + corresponding path. + + \c{CSIDL_APPDATA} usually points to \tt{C:\\Users\\\e{User Name}\\AppData\\Roaming}, + also shown by the environment variable \c{%APPDATA%}. + + \c{CSIDL_COMMON_APPDATA} usually points to \tt{C:\\ProgramData}. On BlackBerry only a single file is used (see \l{Platform Limitations}). If the file format is IniFormat, this is "Settings/MySoft/Star Runner.ini" @@ -3385,8 +3389,8 @@ void QSettings::setUserIniPath(const QString &dir) \table \header \li Platform \li Format \li Scope \li Path - \row \li{1,2} Windows \li{1,2} IniFormat \li UserScope \li \c %APPDATA% - \row \li SystemScope \li \c %COMMON_APPDATA% + \row \li{1,2} Windows \li{1,2} IniFormat \li UserScope \li \c CSIDL_APPDATA + \row \li SystemScope \li \c CSIDL_COMMON_APPDATA \row \li{1,2} Unix \li{1,2} NativeFormat, IniFormat \li UserScope \li \c $HOME/.config \row \li SystemScope \li \c /etc/xdg \row \li{1,2} Qt for Embedded Linux \li{1,2} NativeFormat, IniFormat \li UserScope \li \c $HOME/Settings -- cgit v1.2.3 From ca979a2f69a36712d2bf4d3e4b5b9009c1779a50 Mon Sep 17 00:00:00 2001 From: Venugopal Shivashankar Date: Tue, 16 Aug 2016 16:44:02 +0200 Subject: Doc: Remove references to Windows CE in Qt Core MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The platform is not supported since Qt 5.7 Task-number: QTBUG-55331 Change-Id: I98b90d574d9a76c4281852d93818620b5f489117 Reviewed-by: Topi Reiniƶ --- src/corelib/io/qfile.cpp | 5 ----- src/corelib/io/qfiledevice.cpp | 7 +----- src/corelib/io/qfileinfo.cpp | 3 --- src/corelib/io/qfilesystemwatcher.cpp | 41 ++++++++++++++++++----------------- src/corelib/io/qfsfileengine.cpp | 5 ++--- src/corelib/io/qprocess.cpp | 15 +------------ 6 files changed, 25 insertions(+), 51 deletions(-) (limited to 'src/corelib/io') diff --git a/src/corelib/io/qfile.cpp b/src/corelib/io/qfile.cpp index 9b1bd3a411..41fae69bb2 100644 --- a/src/corelib/io/qfile.cpp +++ b/src/corelib/io/qfile.cpp @@ -923,8 +923,6 @@ bool QFile::open(OpenMode mode) you cannot use this QFile with a QFileInfo. \endlist - \note For Windows CE you may not be able to call resize(). - \sa close() \b{Note for the Windows Platform} @@ -992,9 +990,6 @@ bool QFile::open(FILE *fh, OpenMode mode, FileHandleFlags handleFlags) those cases, size() returns \c 0. See QIODevice::isSequential() for more information. - \warning For Windows CE you may not be able to call seek(), and size() - returns \c 0. - \warning Since this function opens the file without specifying the file name, you cannot use this QFile with a QFileInfo. diff --git a/src/corelib/io/qfiledevice.cpp b/src/corelib/io/qfiledevice.cpp index a2119b74db..20cfa5bdaf 100644 --- a/src/corelib/io/qfiledevice.cpp +++ b/src/corelib/io/qfiledevice.cpp @@ -255,8 +255,6 @@ bool QFileDevice::isSequential() const If the file is not open, or there is an error, handle() returns -1. - This function is not supported on Windows CE. - \sa QSocketNotifier */ int QFileDevice::handle() const @@ -681,8 +679,7 @@ bool QFileDevice::setPermissions(Permissions permissions) be written to disk. Any such modifications will be lost when the memory is unmapped. It is unspecified whether modifications made to the file made after the mapping is created will be visible through - the mapped memory. This flag is not supported on Windows CE. - This enum value was introduced in Qt 5.4. + the mapped memory. This enum value was introduced in Qt 5.4. */ /*! @@ -700,8 +697,6 @@ bool QFileDevice::setPermissions(Permissions permissions) Returns a pointer to the memory or 0 if there is an error. - \note On Windows CE 5.0 the file will be closed before mapping occurs. - \sa unmap() */ uchar *QFileDevice::map(qint64 offset, qint64 size, MemoryMapFlags flags) diff --git a/src/corelib/io/qfileinfo.cpp b/src/corelib/io/qfileinfo.cpp index 8b9efb638a..baf8cbd193 100644 --- a/src/corelib/io/qfileinfo.cpp +++ b/src/corelib/io/qfileinfo.cpp @@ -713,9 +713,6 @@ bool QFileInfo::exists(const QString &file) /*! Refreshes the information about the file, i.e. reads in information from the file system the next time a cached property is fetched. - - \note On Windows CE, there might be a delay for the file system driver - to detect changes on the file. */ void QFileInfo::refresh() { diff --git a/src/corelib/io/qfilesystemwatcher.cpp b/src/corelib/io/qfilesystemwatcher.cpp index a186b34f85..a3915cdf02 100644 --- a/src/corelib/io/qfilesystemwatcher.cpp +++ b/src/corelib/io/qfilesystemwatcher.cpp @@ -174,26 +174,27 @@ void QFileSystemWatcherPrivate::_q_directoryChanged(const QString &path, bool re they have been renamed or removed from disk, and directories once they have been removed from disk. - \note On systems running a Linux kernel without inotify support, - file systems that contain watched paths cannot be unmounted. - - \note Windows CE does not support directory monitoring by - default as this depends on the file system driver installed. - - \note The act of monitoring files and directories for - modifications consumes system resources. This implies there is a - limit to the number of files and directories your process can - monitor simultaneously. On all BSD variants, for - example, an open file descriptor is required for each monitored - file. Some system limits the number of open file descriptors to 256 - by default. This means that addPath() and addPaths() will fail if - your process tries to add more than 256 files or directories to - the file system monitor. Also note that your process may have - other file descriptors open in addition to the ones for files - being monitored, and these other open descriptors also count in - the total. \macos uses a different backend and does not - suffer from this issue. - + \list + \li \b Notes: + \list + \li On systems running a Linux kernel without inotify support, + file systems that contain watched paths cannot be unmounted. + + \li The act of monitoring files and directories for + modifications consumes system resources. This implies there is a + limit to the number of files and directories your process can + monitor simultaneously. On all BSD variants, for + example, an open file descriptor is required for each monitored + file. Some system limits the number of open file descriptors to 256 + by default. This means that addPath() and addPaths() will fail if + your process tries to add more than 256 files or directories to + the file system monitor. Also note that your process may have + other file descriptors open in addition to the ones for files + being monitored, and these other open descriptors also count in + the total. \macos uses a different backend and does not + suffer from this issue. + \endlist + \endlist \sa QFile, QDir */ diff --git a/src/corelib/io/qfsfileengine.cpp b/src/corelib/io/qfsfileengine.cpp index 2cda4d6bda..cd24a54fd0 100644 --- a/src/corelib/io/qfsfileengine.cpp +++ b/src/corelib/io/qfsfileengine.cpp @@ -886,9 +886,8 @@ bool QFSFileEngine::supportsExtension(Extension extension) const /*! \fn QFileInfoList QFSFileEngine::drives() For Windows, returns the list of drives in the file system as a list - of QFileInfo objects. On Unix and Windows CE, only the - root path is returned. On Windows, this function returns all drives - (A:\, C:\, D:\, etc.). + of QFileInfo objects. On Unix, only the root path is returned. + On Windows, this function returns all drives (A:\, C:\, D:\, and so on). For Unix, the list contains just the root path "/". */ diff --git a/src/corelib/io/qprocess.cpp b/src/corelib/io/qprocess.cpp index 3a475c0267..1d10e34018 100644 --- a/src/corelib/io/qprocess.cpp +++ b/src/corelib/io/qprocess.cpp @@ -153,10 +153,6 @@ QT_BEGIN_NAMESPACE On Windows, the variable names are case-insensitive, but case-preserving. QProcessEnvironment behaves accordingly. - On Windows CE, the concept of environment does not exist. This class will - keep the values set for compatibility with other platforms, but the values - set will have no effect on the processes being created. - \sa QProcess, QProcess::systemEnvironment(), QProcess::setProcessEnvironment() */ @@ -505,9 +501,6 @@ void QProcessPrivate::Channel::clear() used as an input source for QXmlReader, or for generating data to be uploaded using QNetworkAccessManager. - \note On Windows CE, reading and writing to a process - is not supported. - When the process exits, QProcess reenters the \l NotRunning state (the initial state), and emits finished(). @@ -753,7 +746,7 @@ void QProcessPrivate::Channel::clear() /*! \typedef QProcess::CreateProcessArgumentModifier - \note This typedef is only available on desktop Windows and Windows CE. + \note This typedef is only available on desktop Windows. On Windows, QProcess uses the Win32 API function \c CreateProcess to start child processes. While QProcess provides a comfortable way to start @@ -1787,9 +1780,6 @@ void QProcess::setEnvironment(const QStringList &environment) using setEnvironment(). If no environment has been set, the environment of the calling process will be used. - \note The environment settings are ignored on Windows CE, - as there is no concept of an environment. - \sa processEnvironment(), setEnvironment(), systemEnvironment() */ QStringList QProcess::environment() const @@ -1823,9 +1813,6 @@ void QProcess::setProcessEnvironment(const QProcessEnvironment &environment) setEnvironment() or setProcessEnvironment(). If no environment has been set, the environment of the calling process will be used. - \note The environment settings are ignored on Windows CE, - as there is no concept of an environment. - \sa setProcessEnvironment(), setEnvironment(), QProcessEnvironment::isEmpty() */ QProcessEnvironment QProcess::processEnvironment() const -- cgit v1.2.3