The following class members are part of the Qt 3 support layer. They are provided to help you port old code to Qt 4. We advise against using them in new code.
enum | ExpandData { NoDirection, Horizontally, Vertically, BothDirections } |
typedef | SizeType |
QSizePolicy ( Policy horizontal, Policy vertical, bool dependent ) | |
QSizePolicy ( Policy horizontal, Policy vertical, uchar horizontalStretch, uchar verticalStretch, bool dependent = false ) | |
Qt::Orientations | expanding () const |
Policy | horData () const |
uint | horStretch () const |
bool | mayGrowHorizontally () const |
bool | mayGrowVertically () const |
bool | mayShrinkHorizontally () const |
bool | mayShrinkVertically () const |
void | setHorData ( Policy policy ) |
void | setHorStretch ( uchar stretch ) |
void | setVerData ( Policy policy ) |
void | setVerStretch ( uchar stretch ) |
Policy | verData () const |
uint | verStretch () const |
Use the Qt::Orientations enum instead.
Constant | Value | Description |
---|---|---|
QSizePolicy::NoDirection | 0x0 | Use 0 instead. |
QSizePolicy::Horizontally | 0x1 | Use Qt::Horizontal instead. |
QSizePolicy::Vertically | 0x2 | Use Qt::Vertical instead. |
QSizePolicy::BothDirections | 0x3 | Use Qt::Horizontal | Qt::Vertical instead. |
Use the QSizePolicy::Policy enum instead.
Use the QSizePolicy() constructor and the setHeightForWidth() function instead.
For example, if you have code like
QSizePolicy *policy = new QSizePolicy(horizontal, vertical, dependent);
you can rewrite it as
QSizePolicy *policy = new QSizePolicy(horizontal, vertical); policy->setHeightForWidth(dependent);
Use the QSizePolicy() constructor and call the setHorizontalStretch(), setVerticalStretch(), and setHeightForWidth() functions instead.
For example, if you have code like
QSizePolicy *policy = new QSizePolicy(horizontal, vertical, horizontalStretch, verticalStretch, dependent);
you can rewrite it as
QSizePolicy *policy = new QSizePolicy(horizontal, vertical); policy->setHorizontalStretch(horizontalStretch); policy->setVerticalStretch(verticalStretch); policy->setHeightForWidth(dependent);
Use expandingDirections() instead.
Use horizontalPolicy() instead.
See also setHorData().
Use horizontalStretch() instead.
See also setHorStretch().
Use the horizontalPolicy() function combined with the QSizePolicy::PolicyFlag enum instead.
For example, if you have code like
bool policy = mayGrowHorizontally();
you can rewrite it as
bool policy = horizontalPolicy() & QSizePolicy::GrowFlag;
Use the verticalPolicy() function combined with the QSizePolicy::PolicyFlag enum instead.
For example, if you have code like
bool policy = mayGrowVertically();
you can rewrite it as
bool policy = verticalPolicy() & QSizePolicy::GrowFlag;
Use the horizontalPolicy() function combined with the QSizePolicy::PolicyFlag enum instead.
For example, if you have code like
bool policy = mayShrinkHorizontally();
you can rewrite it as
bool policy = horizontalPolicy() & QSizePolicy::ShrinkFlag;
Use the verticalPolicy() function combined with the QSizePolicy::PolicyFlag enum instead.
For example, if you have code like
bool policy = mayShrinkVertically();
you can rewrite it as
bool policy = verticalPolicy() & QSizePolicy::ShrinkFlag;
Use setHorizontalPolicy() instead.
See also horData().
Use setHorizontalStretch() instead.
See also horStretch().
Use setVerticalPolicy() instead.
See also verData().
Use setVerticalStretch() instead.
See also verStretch().
Use verticalPolicy() instead.
See also setVerData().
Use verticalStretch() instead.
See also setVerStretch().
© 2008-2011 Nokia Corporation and/or its subsidiaries. Nokia, Qt and their respective logos are trademarks of Nokia Corporation in Finland and/or other countries worldwide.
All other trademarks are property of their respective owners. Privacy Policy
Licensees holding valid Qt Commercial licenses may use this document in accordance with the Qt Commercial License Agreement provided with the Software or, alternatively, in accordance with the terms contained in a written agreement between you and Nokia.
Alternatively, this document may be used under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation.