summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/gui/graphicsview/qgraphicsanchorlayout_p.cpp12
-rw-r--r--src/gui/graphicsview/qgraphicswidget.cpp21
2 files changed, 27 insertions, 6 deletions
diff --git a/src/gui/graphicsview/qgraphicsanchorlayout_p.cpp b/src/gui/graphicsview/qgraphicsanchorlayout_p.cpp
index 7ad994c..96f8930 100644
--- a/src/gui/graphicsview/qgraphicsanchorlayout_p.cpp
+++ b/src/gui/graphicsview/qgraphicsanchorlayout_p.cpp
@@ -966,8 +966,8 @@ void QGraphicsAnchorLayoutPrivate::deleteLayoutEdges()
{
Q_Q(QGraphicsAnchorLayout);
- Q_ASSERT(internalVertex(q, Qt::AnchorHorizontalCenter) == NULL);
- Q_ASSERT(internalVertex(q, Qt::AnchorVerticalCenter) == NULL);
+ Q_ASSERT(!internalVertex(q, Qt::AnchorHorizontalCenter));
+ Q_ASSERT(!internalVertex(q, Qt::AnchorVerticalCenter));
removeAnchor_helper(internalVertex(q, Qt::AnchorLeft),
internalVertex(q, Qt::AnchorRight));
@@ -2036,7 +2036,7 @@ QList<QSimplexConstraint *> QGraphicsAnchorLayoutPrivate::constraintsFromSizeHin
// Look for the layout edge. That can be either the first half in case the
// layout is split in two, or the whole layout anchor.
Orientation orient = Orientation(anchors.first()->orientation);
- AnchorData *layoutEdge = NULL;
+ AnchorData *layoutEdge = 0;
if (layoutCentralVertex[orient]) {
layoutEdge = graph[orient].edgeData(layoutFirstVertex[orient], layoutCentralVertex[orient]);
} else {
@@ -2047,7 +2047,7 @@ QList<QSimplexConstraint *> QGraphicsAnchorLayoutPrivate::constraintsFromSizeHin
// set back the variable to NULL to prevent the continue condition from being
// satisfied in the loop below.
if (layoutEdge->maxSize < QWIDGETSIZE_MAX)
- layoutEdge = NULL;
+ layoutEdge = 0;
}
// For each variable, create constraints based on size hints
@@ -2111,8 +2111,8 @@ QGraphicsAnchorLayoutPrivate::getGraphParts(Orientation orientation)
{
Q_ASSERT(layoutFirstVertex[orientation] && layoutLastVertex[orientation]);
- AnchorData *edgeL1 = NULL;
- AnchorData *edgeL2 = NULL;
+ AnchorData *edgeL1 = 0;
+ AnchorData *edgeL2 = 0;
// The layout may have a single anchor between Left and Right or two half anchors
// passing through the center
diff --git a/src/gui/graphicsview/qgraphicswidget.cpp b/src/gui/graphicsview/qgraphicswidget.cpp
index d70a281..6f910c7 100644
--- a/src/gui/graphicsview/qgraphicswidget.cpp
+++ b/src/gui/graphicsview/qgraphicswidget.cpp
@@ -410,6 +410,27 @@ void QGraphicsWidget::setGeometry(const QRectF &rect)
*/
/*!
+ \property QGraphicsWidget::minimumSize
+ \brief the minimum size of the widget
+
+ \sa setMinimumSize(), minimumSize(), preferredSize, maximumSize
+*/
+
+/*!
+ \property QGraphicsWidget::preferredSize
+ \brief the preferred size of the widget
+
+ \sa setPreferredSize(), preferredSize(), minimumSize, maximumSize
+*/
+
+/*!
+ \property QGraphicsWidget::maximumSize
+ \brief the maximum size of the widget
+
+ \sa setMaximumSize(), maximumSize(), minimumSize, preferredSize
+*/
+
+/*!
Sets the widget's contents margins to \a left, \a top, \a right and \a
bottom.