1 | /**************************************************************************** |
2 | ** |
3 | ** Copyright (C) 2016 The Qt Company Ltd. |
4 | ** Contact: https://www.qt.io/licensing/ |
5 | ** |
6 | ** This file is part of the Qt Designer of the Qt Toolkit. |
7 | ** |
8 | ** $QT_BEGIN_LICENSE:GPL-EXCEPT$ |
9 | ** Commercial License Usage |
10 | ** Licensees holding valid commercial Qt licenses may use this file in |
11 | ** accordance with the commercial license agreement provided with the |
12 | ** Software or, alternatively, in accordance with the terms contained in |
13 | ** a written agreement between you and The Qt Company. For licensing terms |
14 | ** and conditions see https://www.qt.io/terms-conditions. For further |
15 | ** information use the contact form at https://www.qt.io/contact-us. |
16 | ** |
17 | ** GNU General Public License Usage |
18 | ** Alternatively, this file may be used under the terms of the GNU |
19 | ** General Public License version 3 as published by the Free Software |
20 | ** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT |
21 | ** included in the packaging of this file. Please review the following |
22 | ** information to ensure the GNU General Public License requirements will |
23 | ** be met: https://www.gnu.org/licenses/gpl-3.0.html. |
24 | ** |
25 | ** $QT_END_LICENSE$ |
26 | ** |
27 | ****************************************************************************/ |
28 | |
29 | #include "abstractpromotioninterface.h" |
30 | |
31 | QT_BEGIN_NAMESPACE |
32 | |
33 | QDesignerPromotionInterface::~QDesignerPromotionInterface() |
34 | { |
35 | } |
36 | |
37 | /*! |
38 | \class QDesignerPromotionInterface |
39 | |
40 | \brief The QDesignerPromotionInterface provides functions for modifying |
41 | the promoted classes in Designer. |
42 | \inmodule QtDesigner |
43 | \internal |
44 | \since 4.3 |
45 | */ |
46 | |
47 | /*! |
48 | \class QDesignerPromotionInterface::PromotedClass |
49 | \inmodule QtDesigner |
50 | A pair of database items containing the base class and the promoted class. |
51 | */ |
52 | |
53 | /*! |
54 | \typedef QDesignerPromotionInterface::PromotedClasses |
55 | A list of PromotedClass items. |
56 | */ |
57 | |
58 | /*! |
59 | \fn QDesignerPromotionInterface::PromotedClasses QDesignerPromotionInterface::promotedClasses() const |
60 | |
61 | Returns a list of promoted classes along with their base classes in alphabetical order. |
62 | It can be used to populate tree models for editing promoted widgets. |
63 | */ |
64 | |
65 | /*! |
66 | \fn virtual QSet<QString> QDesignerPromotionInterface::referencedPromotedClassNames() const |
67 | |
68 | Returns a set of promoted classed that are referenced by the currently opened forms. |
69 | */ |
70 | |
71 | /*! |
72 | \fn virtual bool QDesignerPromotionInterface::addPromotedClass(const QString &baseClass, const QString &className, const QString &includeFile, QString *errorMessage) |
73 | |
74 | Add a promoted class named \a with the base class \a and include file \a includeFile. Returns \c true on success or \c false along |
75 | with an error message in \a errorMessage on failure. |
76 | */ |
77 | |
78 | /*! |
79 | \fn virtual bool QDesignerPromotionInterface::removePromotedClass(const QString &className, QString *errorMessage) |
80 | |
81 | Remove the promoted class named \a className unless it is referenced by a form. Returns \c true on success or \c false along |
82 | with an error message in \a errorMessage on failure. |
83 | */ |
84 | |
85 | /*! |
86 | \fn virtual bool QDesignerPromotionInterface::changePromotedClassName(const QString &oldClassName, const QString &newClassName, QString *errorMessage) |
87 | |
88 | Change the class name of a promoted class from \a oldClassName to \a newClassName. Returns \c true on success or \c false along |
89 | with an error message in \a errorMessage on failure. |
90 | */ |
91 | |
92 | /*! |
93 | \fn virtual bool QDesignerPromotionInterface::setPromotedClassIncludeFile(const QString &className, const QString &includeFile, QString *errorMessage) |
94 | |
95 | Change the include file of a promoted class named \a className to be \a includeFile. Returns \c true on success or \c false along |
96 | with an error message in \a errorMessage on failure. |
97 | */ |
98 | |
99 | /*! \fn virtual QList<QDesignerWidgetDataBaseItemInterface *> QDesignerPromotionInterface::promotionBaseClasses() const |
100 | |
101 | Return a list of base classes that are suitable for promotion. |
102 | */ |
103 | |
104 | QT_END_NAMESPACE |
105 | |