Digital Recipe

[QT] QT 5.0 QStandardPaths와 QDesktopServices 본문

프로그래밍/C/C++/QT

[QT] QT 5.0 QStandardPaths와 QDesktopServices

노리터 2013. 3. 22. 18:43

QT 5.0 QStandardPaths Class와 QDesktopServices Class


QStandardPaths Class

(http://qt-project.org/doc/qt-5.0/qtcore/qstandardpaths.html)

The QStandardPaths class provides methods for accessing standard paths.

This class contains functions to query standard locations on the local filesystem, for common tasks such as user-specific directories or system-wide configuration directories.



QDesktopServices Class

(http://qt-project.org/doc/qt-5.0/qtgui/qdesktopservices.html)


The QDesktopServices class provides methods for accessing common desktop services.

Many desktop environments provide services that can be used by applications to perform common tasks, such as opening a web page, in a way that is both consistent and takes into account the user's application preferences.

This class contains functions that provide simple interfaces to these services that indicate whether they succeeded or failed.

The openUrl() function is used to open files located at arbitrary URLs in external applications. For URLs that correspond to resources on the local filing system (where the URL scheme is "file"), a suitable application will be used to open the file; otherwise, a web browser will be used to fetch and display the file.

The user's desktop settings control whether certain executable file types are opened for browsing, or if they are executed instead. Some desktop environments are configured to prevent users from executing files obtained from non-local URLs, or to ask the user's permission before doing so.


Posted by Hoseok Seo

2013. 03. 22

Comments