1 | /****************************************************************************
|
---|
2 | **
|
---|
3 | ** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
|
---|
4 | ** All rights reserved.
|
---|
5 | ** Contact: Nokia Corporation ([email protected])
|
---|
6 | **
|
---|
7 | ** This file is part of the documentation of the Qt Toolkit.
|
---|
8 | **
|
---|
9 | ** $QT_BEGIN_LICENSE:FDL$
|
---|
10 | ** Commercial Usage
|
---|
11 | ** Licensees holding valid Qt Commercial licenses may use this file in
|
---|
12 | ** accordance with the Qt Commercial License Agreement provided with the
|
---|
13 | ** Software or, alternatively, in accordance with the terms contained in a
|
---|
14 | ** written agreement between you and Nokia.
|
---|
15 | **
|
---|
16 | ** GNU Free Documentation License
|
---|
17 | ** Alternatively, this file may be used under the terms of the GNU Free
|
---|
18 | ** Documentation License version 1.3 as published by the Free Software
|
---|
19 | ** Foundation and appearing in the file included in the packaging of this
|
---|
20 | ** file.
|
---|
21 | **
|
---|
22 | ** If you have questions regarding the use of this file, please contact
|
---|
23 | ** Nokia at [email protected].
|
---|
24 | ** $QT_END_LICENSE$
|
---|
25 | **
|
---|
26 | ****************************************************************************/
|
---|
27 |
|
---|
28 | /*!
|
---|
29 | \class QDesignerLayoutDecorationExtension
|
---|
30 | \brief The QDesignerLayoutDecorationExtension class provides an extension to a layout in \QD.
|
---|
31 | \inmodule QtDesigner
|
---|
32 | \internal
|
---|
33 | */
|
---|
34 |
|
---|
35 | /*!
|
---|
36 | \enum QDesignerLayoutDecorationExtension::InsertMode
|
---|
37 |
|
---|
38 | This enum describes the modes that are used to insert items into a layout.
|
---|
39 |
|
---|
40 | \value InsertWidgetMode Widgets are inserted into empty cells in a layout.
|
---|
41 | \value InsertRowMode Whole rows are inserted into a vertical or grid layout.
|
---|
42 | \value InsertColumnMode Whole columns are inserted into a horizontal or grid layout.
|
---|
43 | */
|
---|
44 |
|
---|
45 | /*!
|
---|
46 | \fn virtual QDesignerLayoutDecorationExtension::~QDesignerLayoutDecorationExtension()
|
---|
47 |
|
---|
48 | Destroys the extension.
|
---|
49 | */
|
---|
50 |
|
---|
51 | /*!
|
---|
52 | \fn virtual QList<QWidget*> QDesignerLayoutDecorationExtension::widgets(QLayout *layout) const
|
---|
53 |
|
---|
54 | Returns the widgets that are managed by the given \a layout.
|
---|
55 |
|
---|
56 | \sa insertWidget(), removeWidget()
|
---|
57 | */
|
---|
58 |
|
---|
59 | /*!
|
---|
60 | \fn QRect QDesignerLayoutDecorationExtension::itemInfo(int index) const
|
---|
61 |
|
---|
62 | Returns the rectangle covered by the item at the given \a index in the layout.
|
---|
63 | */
|
---|
64 |
|
---|
65 | /*!
|
---|
66 | \fn int QDesignerLayoutDecorationExtension::indexOf(QWidget *widget) const
|
---|
67 |
|
---|
68 | Returns the index of the specified \a widget in the layout.
|
---|
69 | */
|
---|
70 |
|
---|
71 | /*!
|
---|
72 | \fn int QDesignerLayoutDecorationExtension::indexOf(QLayoutItem *item) const
|
---|
73 |
|
---|
74 | Returns the index of the specified layout \a item.
|
---|
75 | */
|
---|
76 |
|
---|
77 | /*!
|
---|
78 | \fn QDesignerLayoutDecorationExtension::InsertMode QDesignerLayoutDecorationExtension::currentInsertMode() const
|
---|
79 |
|
---|
80 | Returns the current insertion mode.
|
---|
81 | */
|
---|
82 |
|
---|
83 | /*!
|
---|
84 | \fn int QDesignerLayoutDecorationExtension::currentIndex() const
|
---|
85 |
|
---|
86 | Returns the current index in the layout.
|
---|
87 | */
|
---|
88 |
|
---|
89 | /*!
|
---|
90 | \fn QPair<int, int> QDesignerLayoutDecorationExtension::currentCell() const
|
---|
91 |
|
---|
92 | Returns a pair containing the row and column of the current cell in the layout.
|
---|
93 | */
|
---|
94 |
|
---|
95 | /*!
|
---|
96 | \fn void QDesignerLayoutDecorationExtension::insertWidget(QWidget *widget, const QPair<int, int> &cell)
|
---|
97 |
|
---|
98 | Inserts the given \a widget into the specified \a cell in the layout.
|
---|
99 |
|
---|
100 | \sa removeWidget()
|
---|
101 | */
|
---|
102 |
|
---|
103 | /*!
|
---|
104 | \fn void QDesignerLayoutDecorationExtension::removeWidget(QWidget *widget)
|
---|
105 |
|
---|
106 | Removes the specified \a widget from the layout.
|
---|
107 |
|
---|
108 | \sa insertWidget()
|
---|
109 | */
|
---|
110 |
|
---|
111 | /*!
|
---|
112 | \fn void QDesignerLayoutDecorationExtension::insertRow(int row)
|
---|
113 |
|
---|
114 | Inserts a new row into the form at the position specified by \a row.
|
---|
115 | */
|
---|
116 |
|
---|
117 | /*!
|
---|
118 | \fn void QDesignerLayoutDecorationExtension::insertColumn(int column)
|
---|
119 |
|
---|
120 | Inserts a new column into the form at the position specified by \a column.
|
---|
121 | */
|
---|
122 |
|
---|
123 | /*!
|
---|
124 | \fn void QDesignerLayoutDecorationExtension::simplify()
|
---|
125 |
|
---|
126 | Simplifies the layout by removing unnecessary empty rows and columns, and by changing the
|
---|
127 | number of rows or columns spanned by widgets.
|
---|
128 | */
|
---|
129 |
|
---|
130 | /*!
|
---|
131 | \fn int QDesignerLayoutDecorationExtension::findItemAt(const QPoint &position) const
|
---|
132 |
|
---|
133 | Returns the index of the item in the layout that covers the given \a position.
|
---|
134 | */
|
---|
135 |
|
---|
136 | /*!
|
---|
137 | \fn int QDesignerLayoutDecorationExtension::findItemAt(int row, int column) const
|
---|
138 |
|
---|
139 | Returns the item in the layout that occupies the specified \a row and \a column in the layout.
|
---|
140 |
|
---|
141 | Currently, this only applies to grid layouts.
|
---|
142 | */
|
---|
143 |
|
---|
144 | /*!
|
---|
145 | \fn void QDesignerLayoutDecorationExtension::adjustIndicator(const QPoint &position, int index)
|
---|
146 |
|
---|
147 | Adjusts the indicator for the item specified by \a index so that
|
---|
148 | it lies at the given \a position on the form.
|
---|
149 | */
|
---|