Qt wiki will be updated on October 12th 2023 starting at 11:30 AM (EEST) and the maintenance will last around 2-3 hours. During the maintenance the site will be unavailable.
How to Launch Web Browser: Difference between revisions
Jump to navigation
Jump to search
AutoSpider (talk | contribs) (Add "cleanup" tag) |
(Sub-categorize) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
{{ | {{LangSwitch}} | ||
[[Category:Snippets::Misc]] | |||
[[Category: | |||
[[Category:HowTo]] | [[Category:HowTo]] | ||
The class {{DocLink|QDesktopServices}} provides methods for accessing common desktop services such as opening a URL in the default web browser. | |||
The class | |||
Please do not forget to include the following header files: | Please do not forget to include the following header files: | ||
Line 14: | Line 8: | ||
#include <QDesktopServices> | #include <QDesktopServices> | ||
#include <QUrl> | #include <QUrl> | ||
QDesktopServices::openUrl(QUrl("https://qt.io/")); | QDesktopServices::openUrl(QUrl("https://qt.io/")); | ||
</code> | </code> | ||
Latest revision as of 11:59, 28 November 2016
The class QDesktopServices provides methods for accessing common desktop services such as opening a URL in the default web browser.
Please do not forget to include the following header files:
#include <QDesktopServices>
#include <QUrl>
QDesktopServices::openUrl(QUrl("https://qt.io/"));