From af7f7732cb52888c468b3e86a67e61b83fee11e2 Mon Sep 17 00:00:00 2001 From: Topi Reinio Date: Mon, 23 Nov 2020 10:51:57 +0100 Subject: Doc: Document BINDABLE attribute for Q_PROPERTY macro Pick-to: 6.0 Fixes: QTBUG-87036 Change-Id: Ia6067d887b9b697dbcb8e02bce5a560a8ac5eaf3 Reviewed-by: Paul Wicking Reviewed-by: Lars Knoll --- src/corelib/doc/snippets/code/doc_src_properties.cpp | 1 + src/corelib/doc/src/objectmodel/properties.qdoc | 6 ++++++ 2 files changed, 7 insertions(+) (limited to 'src/corelib') diff --git a/src/corelib/doc/snippets/code/doc_src_properties.cpp b/src/corelib/doc/snippets/code/doc_src_properties.cpp index 5a5627abfd..838cb980f7 100644 --- a/src/corelib/doc/snippets/code/doc_src_properties.cpp +++ b/src/corelib/doc/snippets/code/doc_src_properties.cpp @@ -59,6 +59,7 @@ Q_PROPERTY(type name [SCRIPTABLE bool] [STORED bool] [USER bool] + [BINDABLE bindableProperty] [CONSTANT] [FINAL] [REQUIRED]) diff --git a/src/corelib/doc/src/objectmodel/properties.qdoc b/src/corelib/doc/src/objectmodel/properties.qdoc index e3c506e8bc..9a2517e050 100644 --- a/src/corelib/doc/src/objectmodel/properties.qdoc +++ b/src/corelib/doc/src/objectmodel/properties.qdoc @@ -131,6 +131,12 @@ editable property for (checkable) buttons. Note that QItemDelegate gets and sets a widget's \c USER property. + \li The \c {BINDABLE bindableProperty} attribute indicates that the + property supports bindings, and that it is possible to set and inspect + bindings to this property via the meta object system (QMetaProperty). + \c bindableProperty names a class member of type QBindable, where T + is the property type. This attribute was introduced in Qt 6.0. + \li The presence of the \c CONSTANT attribute indicates that the property value is constant. For a given object instance, the READ method of a constant property must return the same value every time it is called. This -- cgit v1.2.3