Changeset View
Changeset View
Standalone View
Standalone View
src/formeditor/WidgetInfo.h
1 | /* This file is part of the KDE project | 1 | /* This file is part of the KDE project | ||
---|---|---|---|---|---|
2 | Copyright (C) 2003 Lucijan Busch <lucijan@gmx.at> | 2 | Copyright (C) 2003 Lucijan Busch <lucijan@gmx.at> | ||
3 | Copyright (C) 2004 Cedric Pasteur <cedric.pasteur@free.fr> | 3 | Copyright (C) 2004 Cedric Pasteur <cedric.pasteur@free.fr> | ||
4 | Copyright (C) 2004-2009 Jarosław Staniek <staniek@kde.org> | 4 | Copyright (C) 2004-2017 Jarosław Staniek <staniek@kde.org> | ||
5 | 5 | | |||
6 | This library is free software; you can redistribute it and/or | 6 | This library is free software; you can redistribute it and/or | ||
7 | modify it under the terms of the GNU Library General Public | 7 | modify it under the terms of the GNU Library General Public | ||
8 | License as published by the Free Software Foundation; either | 8 | License as published by the Free Software Foundation; either | ||
9 | version 2 of the License, or (at your option) any later version. | 9 | version 2 of the License, or (at your option) any later version. | ||
10 | 10 | | |||
11 | This library is distributed in the hope that it will be useful, | 11 | This library is distributed in the hope that it will be useful, | ||
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
▲ Show 20 Lines • Show All 144 Lines • ▼ Show 20 Line(s) | 40 | public: | |||
157 | to describe class' details. */ | 157 | to describe class' details. */ | ||
158 | QVariant internalProperty(const QByteArray& property) const; | 158 | QVariant internalProperty(const QByteArray& property) const; | ||
159 | 159 | | |||
160 | /*! Assigns @a value for internal property @a property. | 160 | /*! Assigns @a value for internal property @a property. | ||
161 | Internal properties are not stored within objects, but can be provided | 161 | Internal properties are not stored within objects, but can be provided | ||
162 | to describe class' details. */ | 162 | to describe class' details. */ | ||
163 | void setInternalProperty(const QByteArray& property, const QVariant& value); | 163 | void setInternalProperty(const QByteArray& property, const QVariant& value); | ||
164 | 164 | | |||
165 | /** | ||||
166 | * @brief Returns @c alignment flags supports by the widget | ||||
167 | * | ||||
168 | * By default returns all possible flags minus Qt::AlignAbsolute. | ||||
169 | * @see setSupportedAlignmentFlags | ||||
170 | */ | ||||
171 | Qt::Alignment supportedAlignmentFlags() const; | ||||
172 | | ||||
173 | /** | ||||
174 | * @brief Sets alignment flags supported by the widget | ||||
175 | * | ||||
176 | * Used for example by an image box that does not support justified, absolute and baseline | ||||
177 | * alignment. | ||||
178 | * @see supportedAlignmentFlags | ||||
179 | */ | ||||
180 | void setSupportedAlignmentFlags(Qt::Alignment flags); | ||||
181 | | ||||
165 | protected: | 182 | protected: | ||
166 | void setInheritedClass(WidgetInfo *inheritedClass); | 183 | void setInheritedClass(WidgetInfo *inheritedClass); | ||
167 | 184 | | |||
168 | private: | 185 | private: | ||
169 | class Private; | 186 | class Private; | ||
170 | Private * const d; | 187 | Private * const d; | ||
171 | 188 | | |||
172 | friend class WidgetLibrary; | 189 | friend class WidgetLibrary; | ||
173 | }; | 190 | }; | ||
174 | 191 | | |||
175 | } // namespace KFormDesigner | 192 | } // namespace KFormDesigner | ||
176 | 193 | | |||
177 | #endif | 194 | #endif |