dRonin  adbada4
dRonin GCS
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Groups Pages
iwizard.h
Go to the documentation of this file.
1 
13 /*
14  * This program is free software; you can redistribute it and/or modify
15  * it under the terms of the GNU General Public License as published by
16  * the Free Software Foundation; either version 3 of the License, or
17  * (at your option) any later version.
18  *
19  * This program is distributed in the hope that it will be useful, but
20  * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
21  * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
22  * for more details.
23  *
24  * You should have received a copy of the GNU General Public License along
25  * with this program; if not, see <http://www.gnu.org/licenses/>
26  */
27 
28 #ifndef IWIZARD_H
29 #define IWIZARD_H
30 
31 #include <coreplugin/core_global.h>
32 #include <QtCore/QObject>
33 
34 QT_BEGIN_NAMESPACE
35 class QIcon;
36 QT_END_NAMESPACE
37 
38 namespace Core {
39 
40 class CORE_EXPORT IWizard : public QObject
41 {
42  Q_OBJECT
43 public:
44  enum Kind { FileWizard, ClassWizard, ProjectWizard };
45 
46  IWizard(QObject *parent = nullptr)
47  : QObject(parent)
48  {
49  }
50  virtual ~IWizard() {}
51 
52  virtual Kind kind() const = 0;
53  virtual QIcon icon() const = 0;
54  virtual QString description() const = 0;
55  virtual QString name() const = 0;
56 
57  virtual QString category() const = 0;
58  virtual QString trCategory() const = 0;
59 
60  virtual QStringList runWizard(const QString &path, QWidget *parent) = 0;
61 
62  // Utility to find all registered wizards
63  static QList<IWizard *> allWizards();
64  // Utility to find all registered wizards of a certain kind
65  static QList<IWizard *> wizardsOfKind(Kind kind);
66 };
67 
68 } // namespace Core
69 
70 #endif // IWIZARD_H
virtual ~IWizard()
Definition: iwizard.h:50
IWizard(QObject *parent=nullptr)
Definition: iwizard.h:46
The class IWizard is the base class for all wizards (for example shown in {File | New})...
Definition: iwizard.h:40
Definition: icore.h:39