summaryrefslogtreecommitdiffstats
path: root/src/widgets
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2020-09-14 08:44:42 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2020-09-15 00:46:49 +0000
commit366564056d92073ec2e24ff8f3ceaa3ef4db8ec8 (patch)
tree5883bd9fb76a7e6520a8075d434f526b864afa6d /src/widgets
parentfb65b32d7621f065ec854f1e72828720bffb3b39 (diff)
QLayout: Make contentsMargins a Q_PROPERTY
It replaces the deprecated int margins property, which was a Q_PROPERTY. This enables Qt for Python users to use property syntax for it. Task-number: PYSIDE-1019 Change-Id: I958d2ef7f8e2afcc2be490e29d4b11c070569fbd Reviewed-by: Christian Tismer <tismer@stackless.com> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/kernel/qlayout.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/widgets/kernel/qlayout.h b/src/widgets/kernel/qlayout.h
index 1e51ff8fde..0a887e833c 100644
--- a/src/widgets/kernel/qlayout.h
+++ b/src/widgets/kernel/qlayout.h
@@ -64,6 +64,7 @@ class Q_WIDGETS_EXPORT QLayout : public QObject, public QLayoutItem
Q_DECLARE_PRIVATE(QLayout)
Q_PROPERTY(int spacing READ spacing WRITE setSpacing)
+ Q_PROPERTY(QMargins contentsMargins READ contentsMargins WRITE setContentsMargins)
Q_PROPERTY(SizeConstraint sizeConstraint READ sizeConstraint WRITE setSizeConstraint)
public:
enum SizeConstraint {