46 #ifdef QT_INCLUDE_COMPAT
58 class QGridLayoutPrivate;
64 QDOC_PROPERTY(
int horizontalSpacing READ horizontalSpacing WRITE setHorizontalSpacing)
65 QDOC_PROPERTY(
int verticalSpacing READ verticalSpacing WRITE setVerticalSpacing)
73 int spacing = -1,
const char *
name = 0);
74 QT3_SUPPORT_CONSTRUCTOR QGridLayout(
int nRows ,
int nCols = 1,
int spacing = -1,
const char *
name = 0);
75 QT3_SUPPORT_CONSTRUCTOR QGridLayout(QLayout *parentLayout,
int nRows = 1,
int nCols = 1,
int spacing = -1,
76 const char *
name = 0);
80 QSize sizeHint()
const;
81 QSize minimumSize()
const;
82 QSize maximumSize()
const;
84 void setHorizontalSpacing(
int spacing);
85 int horizontalSpacing()
const;
86 void setVerticalSpacing(
int spacing);
87 int verticalSpacing()
const;
88 void setSpacing(
int spacing);
91 void setRowStretch(
int row,
int stretch);
92 void setColumnStretch(
int column,
int stretch);
93 int rowStretch(
int row)
const;
94 int columnStretch(
int column)
const;
96 void setRowMinimumHeight(
int row,
int minSize);
97 void setColumnMinimumWidth(
int column,
int minSize);
98 int rowMinimumHeight(
int row)
const;
99 int columnMinimumWidth(
int column)
const;
101 int columnCount()
const;
102 int rowCount()
const;
104 QRect cellRect(
int row,
int column)
const;
106 inline QT3_SUPPORT
QRect cellGeometry(
int row,
int column)
const {
return cellRect(row, column);}
109 bool hasHeightForWidth()
const;
110 int heightForWidth(
int)
const;
111 int minimumHeightForWidth(
int)
const;
113 Qt::Orientations expandingDirections()
const;
117 void addWidget(
QWidget *,
int row,
int column, Qt::Alignment = 0);
118 void addWidget(
QWidget *,
int row,
int column,
int rowSpan,
int columnSpan, Qt::Alignment = 0);
119 void addLayout(QLayout *,
int row,
int column, Qt::Alignment = 0);
120 void addLayout(QLayout *,
int row,
int column,
int rowSpan,
int columnSpan, Qt::Alignment = 0);
126 inline QT3_SUPPORT
void setOrigin(
Qt::Corner corner) { setOriginCorner(corner); }
127 inline QT3_SUPPORT
Qt::Corner origin()
const {
return originCorner(); }
130 QLayoutItem *itemAtPosition(
int row,
int column)
const;
133 void setGeometry(
const QRect&);
135 void addItem(
QLayoutItem *item,
int row,
int column,
int rowSpan = 1,
int columnSpan = 1, Qt::Alignment = 0);
138 void getItemPosition(
int idx,
int *row,
int *column,
int *rowSpan,
int *columnSpan);
142 QT3_SUPPORT
bool findWidget(
QWidget*
w,
int *
r,
int *
c);
147 Q_DISABLE_COPY(QGridLayout)
151 QT3_SUPPORT
void expand(
int rows,
int cols);
152 inline QT3_SUPPORT
void addRowSpacing(
int row,
int minsize) { addItem(
new QSpacerItem(0,minsize), row, 0); }
153 inline QT3_SUPPORT
void addColSpacing(
int col,
int minsize) { addItem(
new QSpacerItem(minsize,0), 0, col); }
154 inline QT3_SUPPORT
void addMultiCellWidget(
QWidget *
w,
int fromRow,
int toRow,
int fromCol,
int toCol, Qt::Alignment _align = 0)
155 { addWidget(w, fromRow, fromCol, (toRow < 0) ? -1 : toRow - fromRow + 1, (toCol < 0) ? -1 : toCol - fromCol + 1, _align); }
156 inline QT3_SUPPORT
void addMultiCell(
QLayoutItem *l,
int fromRow,
int toRow,
int fromCol,
int toCol, Qt::Alignment _align = 0)
157 { addItem(l, fromRow, fromCol, (toRow < 0) ? -1 : toRow - fromRow + 1, (toCol < 0) ? -1 : toCol - fromCol + 1, _align); }
158 inline QT3_SUPPORT
void addMultiCellLayout(QLayout *layout,
int fromRow,
int toRow,
int fromCol,
int toCol, Qt::Alignment _align = 0)
159 { addLayout(layout, fromRow, fromCol, (toRow < 0) ? -1 : toRow - fromRow + 1, (toCol < 0) ? -1 : toCol - fromCol + 1, _align); }
161 inline QT3_SUPPORT
int numRows()
const {
return rowCount(); }
162 inline QT3_SUPPORT
int numCols()
const {
return columnCount(); }
163 inline QT3_SUPPORT
void setColStretch(
int col,
int stretch) {setColumnStretch(col, stretch); }
164 inline QT3_SUPPORT
int colStretch(
int col)
const {
return columnStretch(col); }
165 inline QT3_SUPPORT
void setColSpacing(
int col,
int minSize) { setColumnMinimumWidth(col, minSize); }
166 inline QT3_SUPPORT
int colSpacing(
int col)
const {
return columnMinimumWidth(col); }
167 inline QT3_SUPPORT
void setRowSpacing(
int row,
int minSize) {setRowMinimumHeight(row, minSize); }
168 inline QT3_SUPPORT
int rowSpacing(
int row)
const {
return rowMinimumHeight(row); }
176 #endif // QGRIDLAYOUT_H
GLdouble GLdouble GLdouble r
GLenum GLenum GLvoid * row
#define QT_BEGIN_NAMESPACE
GLuint GLuint GLsizei count
GLint GLint GLsizei GLsizei GLsizei GLint border
GLenum GLenum GLvoid GLvoid * column
GLuint const GLchar * name
void addWidget(QWidget *w)
GLubyte GLubyte GLubyte GLubyte w
void addWidget(QWidget *w)