Qt Utilities  5.6.0
Common Qt related C++ classes and routines used by my applications such as dialogs, widgets and models
dialogutils.h
Go to the documentation of this file.
1 #ifndef DIALOGS_DIALOGUTILS_H
2 #define DIALOGS_DIALOGUTILS_H
3 
4 #include "../global.h"
5 
6 #include <QtGlobal>
7 
8 QT_FORWARD_DECLARE_CLASS(QString)
9 QT_FORWARD_DECLARE_CLASS(QWidget)
10 QT_FORWARD_DECLARE_CLASS(QColor)
11 
12 namespace Dialogs {
13 
17 enum class DocumentStatus {
18  NoDocument,
19  Saved,
20  Unsaved
21 };
22 
23 QString QT_UTILITIES_EXPORT generateWindowTitle(DocumentStatus documentStatus, const QString &documentPath);
24 
25 #ifndef GUI_NONE
26 # ifdef Q_OS_WIN32
27 QColor QT_UTILITIES_EXPORT windowFrameColor();
28 QColor QT_UTILITIES_EXPORT instructionTextColor();
29 # endif
30 const QString QT_UTILITIES_EXPORT &dialogStyle();
31 # ifdef GUI_QTWIDGETS
32 void QT_UTILITIES_EXPORT centerWidget(QWidget *widget);
33 void QT_UTILITIES_EXPORT cornerWidget(QWidget *widget);
34 void QT_UTILITIES_EXPORT makeHeading(QWidget *widget);
35 void QT_UTILITIES_EXPORT updateStyle(QWidget *widget);
36 # endif
37 #endif
38 
39 } // namespace Dialogs
40 
41 #endif // DIALOGS_DIALOGUTILS_H
QString QT_UTILITIES_EXPORT generateWindowTitle(DocumentStatus documentStatus, const QString &documentPath)
Generates the window title string for the specified documentStatus and documentPath.
Definition: dialogutils.cpp:25
DocumentStatus
The DocumentStatus enum specifies the status of the document in a window.
Definition: dialogutils.h:17
#define QT_UTILITIES_EXPORT
Marks the symbol to be exported by the qtutilities library.
Provides common dialogs such as AboutDialog, EnterPasswordDialog and SettingsDialog.
Definition: dialogutils.h:12
const QString QT_UTILITIES_EXPORT & dialogStyle()
Returns the stylesheet for dialogs and other windows used in my applications.
Definition: dialogutils.cpp:75