Qt Utilities 6.13.5
Common Qt related C++ classes and routines used by my applications such as dialogs, widgets and models
Loading...
Searching...
No Matches
desktoputils.h
Go to the documentation of this file.
1#ifndef DESKTOP_UTILS_DESKTOPSERVICES_H
2#define DESKTOP_UTILS_DESKTOPSERVICES_H
3
4#include "../global.h"
5
6#include <QPalette>
7
8#include <optional>
9
10QT_FORWARD_DECLARE_CLASS(QString)
11
12namespace QtUtilities {
13
14QT_UTILITIES_EXPORT bool openLocalFileOrDir(const QString &path);
15QT_UTILITIES_EXPORT bool isPaletteDark(const QPalette &palette = QPalette());
16QT_UTILITIES_EXPORT std::optional<bool> isDarkModeEnabled();
17
18} // namespace QtUtilities
19
20#endif // DESKTOP_UTILS_DESKTOPSERVICES_H
#define QT_UTILITIES_EXPORT
Marks the symbol to be exported by the qtutilities library.
Definition global.h:14
QT_UTILITIES_EXPORT std::optional< bool > isDarkModeEnabled()
Returns whether dark mode is enabled.
QT_UTILITIES_EXPORT bool isPaletteDark(const QPalette &palette=QPalette())
Returns whether palette is dark.
QT_UTILITIES_EXPORT bool openLocalFileOrDir(const QString &path)
Shows the specified file or directory using the default file browser.