> Sorry, I'm lost now. If you store them both and apply them in either
> order, shouldn't the result be correct no matter what?

That doesn't matter in fact. If you change orientation first, then sizePolicy, 
you get the state
which can't be reliably stored / read, unless you explicitly know that there is
hidden dependency (if you know, you may influence the order or storing / 
reading,
but still it's not orthogonal).

________________________________
From: Giuseppe D'Angelo
Sent: Tuesday, October 29, 2019 12:13 PM
To: Jaroslaw Kobus; Volker Hilsheimer
Cc: [email protected]
Subject: Re: [Development] Issues with QFormBuilder - All properties modified & 
Invalid UI

On 29/10/2019 11:32, Jaroslaw Kobus wrote:
> Take any of QWidget's properties, e.g. sizePolicy, grep through qt sources
> and search where setSizePolicy is used - QAbstractSlider::setOrientation(),
> so "orientation" property of abstract slider influences "sizePolicy" - 
> non-orthogonality detected.
> If you store both properties, and then read them - the result depend on the 
> read order.

Sorry, I'm lost now. If you store them both and apply them in either
order, shouldn't the result be correct no matter what?

==

If this is not true for some case: we have an API problem, and we can
debate whether it's in the class featuring interlinked properties, or in
the meta property system that is not clearly reflecting the
dependencies, thus making a (de)serializer of such properties impossible
to write correctly. And the latter has way more profound implications
than just serializing the state of a QObject (e.g. thinking of IPC like
DBus, QtRO, etc.).

Thanks,
--
Giuseppe D'Angelo | [email protected] | Senior Software Engineer
KDAB (France) S.A.S., a KDAB Group company
Tel. France +33 (0)4 90 84 08 53, http://www.kdab.com
KDAB - The Qt, C++ and OpenGL Experts

_______________________________________________
Development mailing list
[email protected]
https://lists.qt-project.org/listinfo/development

Reply via email to