QDesignerDialogGuiInterface Class
The QDesignerDialogGuiInterface allows integrations of Qt Designer to replace the message boxes displayed by Qt Designer by custom dialogs. More...
Header: | #include <QDesignerDialogGuiInterface> |
Public Types
enum | Message { FormLoadFailureMessage, UiVersionMismatchMessage, ResourceLoadFailureMessage, TopLevelSpacerMessage, PropertyEditorMessage, …, OtherMessage } |
Public Functions
QDesignerDialogGuiInterface() | |
virtual | ~QDesignerDialogGuiInterface() |
virtual QString | getOpenImageFileName(QWidget *parent = nullptr, const QString &caption = QString(), const QString &dir = QString(), const QString &filter = QString(), QString *selectedFilter = nullptr, QFileDialog::Options options = {}) |
virtual QStringList | getOpenImageFileNames(QWidget *parent = nullptr, const QString &caption = QString(), const QString &dir = QString(), const QString &filter = QString(), QString *selectedFilter = nullptr, QFileDialog::Options options = {}) |
Detailed Description
\since
4.4 \internal
\inmodule
QtDesigner
QDesignerDialogGuiInterface provides virtual functions that can be overwritten to display message boxes and file dialogs.
See also QMessageBox and QFileDialog.
Member Type Documentation
enum QDesignerDialogGuiInterface::Message
This enum specifies the context from within the message box is called.
Constant | Value | Description |
---|---|---|
QDesignerDialogGuiInterface::FormLoadFailureMessage | 0 | Loading of a form failed |
QDesignerDialogGuiInterface::UiVersionMismatchMessage | 1 | Attempt to load a file created with an old version of Designer |
QDesignerDialogGuiInterface::ResourceLoadFailureMessage | 2 | Resources specified in a file could not be found |
QDesignerDialogGuiInterface::TopLevelSpacerMessage | 3 | Spacer items detected on a container without layout |
QDesignerDialogGuiInterface::PropertyEditorMessage | 4 | Messages of the propert yeditor |
QDesignerDialogGuiInterface::SignalSlotEditorMessage | 5 | Messages of the signal / slot editor |
QDesignerDialogGuiInterface::FormEditorMessage | 6 | Messages of the form editor |
QDesignerDialogGuiInterface::PreviewFailureMessage | 7 | A preview could not be created |
QDesignerDialogGuiInterface::PromotionErrorMessage | 8 | Messages related to promotion of a widget |
QDesignerDialogGuiInterface::ResourceEditorMessage | 9 | Messages of the resource editor |
QDesignerDialogGuiInterface::ScriptDialogMessage | 10 | Messages of the script dialog |
QDesignerDialogGuiInterface::SignalSlotDialogMessage | 11 | Messages of the signal slot dialog |
QDesignerDialogGuiInterface::OtherMessage | 12 | Unspecified context |
Member Function Documentation
QDesignerDialogGuiInterface::QDesignerDialogGuiInterface()
Constructs a QDesignerDialogGuiInterface object.
[virtual noexcept]
QDesignerDialogGuiInterface::~QDesignerDialogGuiInterface()
Destroys the QDesignerDialogGuiInterface object.
[virtual]
QString QDesignerDialogGuiInterface::getOpenImageFileName(QWidget *parent = nullptr, const QString &caption = QString(), const QString &dir = QString(), const QString &filter = QString(), QString *selectedFilter = nullptr, QFileDialog::Options options = {})
Opens a file dialog with image browsing capabilities as child of parent using the parameters caption, dir, filter, selectedFilter and options that prompts the user for an existing file. Returns a file selected by the user.
The default implementation simply calls getOpenFileName(). On platforms that do not support an image preview in the QFileDialog, the function can be reimplemented to provide an image browser.
\since
4.5
[virtual]
QStringList QDesignerDialogGuiInterface::getOpenImageFileNames(QWidget *parent = nullptr, const QString &caption = QString(), const QString &dir = QString(), const QString &filter = QString(), QString *selectedFilter = nullptr, QFileDialog::Options options = {})
Opens a file dialog with image browsing capabilities as child of parent using the parameters caption, dir, filter, selectedFilter and options that prompts the user for a set of existing files. Returns one or more existing files selected by the user.
The default implementation simply calls getOpenFileNames(). On platforms that do not support an image preview in the QFileDialog, the function can be reimplemented to provide an image browser.
\since
4.5