Re: [Qt-qml] How to think about Attached Properties?

2010-12-05 Thread bea.lam
Hi Charley, > > In the case where I have MyAttachedProperties, must the nested "b.c.d" > actually be nested within each other (with each of "b" and "c" derived from > QObject and exposed to QML), or is there a way I could "map" the "b.c.d" to > some application-specific attribute within MyAtta

Re: [Qt-qml] How to think about Attached Properties?

2010-12-01 Thread Charley Bay
Ok, follow-up, I'm still trying to understand setting properties in the QObject::setProperty() meta-object system versus exposing a data member as a property (and how these options relate to attached properties). Reading the QML docs: QUOTING

Re: [Qt-qml] How to think about Attached Properties?

2010-12-01 Thread Charley Bay
> > charley asketh: > > (1) Logically, should the "state" for MyAttachedProperties simply reside > within the QObject meta-object system (e.g., through the QObject (base) > "property()/setProperty()")? Or, can I have my own "state" in data members > for MyAttachedProperties that I "expose" as prop

Re: [Qt-qml] How to think about Attached Properties?

2010-11-30 Thread bea.lam
Hi Charley, On 27/11/2010, at 11:45 AM, ext Charley Bay wrote: > I'm implementing "attached properties" on my custom C++ type (exposed to > QML), and am unsure about the "proper" use model: > > > > For example, I did: > > (a) Implement C++ clas

[Qt-qml] How to think about Attached Properties?

2010-11-26 Thread Charley Bay
I'm implementing "attached properties" on my custom C++ type (exposed to QML), and am unsure about the "proper" use model: For example, I did: (a) Implement C++ class MyAttachedProperties, derived from QObject (b) Implement static function and QM