[Interest] How can i animate Layout.preferredWidth and friends?

Mark markg85 at gmail.com
Tue Oct 8 16:32:32 CEST 2013


On Wed, Oct 2, 2013 at 2:25 PM, Mark <markg85 at gmail.com> wrote:

> On Wed, Oct 2, 2013 at 11:51 AM, Saether Jan-Arve <
> Jan-Arve.Saether at digia.com> wrote:
>
>>  Of course it should not crash.****
>>
>> I get an ASSERT: "mo" in file qml\qqmlvme.cpp, line 849 (this is with
>> current stable branch though).****
>>
>> ** **
>>
>> I'm a bit curious to know why do you want to animate that property?****
>>
>> What do you want to achieve?****
>>
>> ** **
>>
>> Jan Arve****
>>
>> ** **
>>
>> *From:* interest-bounces+jan-arve.saether=digia.com at qt-project.org[mailto:
>> interest-bounces+jan-arve.saether=digia.com at qt-project.org] *On Behalf
>> Of *Mark
>> *Sent:* 30. september 2013 01:40
>> *To:* Qt Interest
>> *Subject:* [Interest] How can i animate Layout.preferredWidth and
>> friends?****
>>
>> ** **
>>
>> Hi,****
>>
>> ** **
>>
>> I thought something as simple as:****
>>
>> ** **
>>
>>             Behavior on Layout.preferredWidth {****
>>
>>                 NumberAnimation { duration: 1000 }****
>>
>>             }****
>>
>> ** **
>>
>> would do.. Apparently not since it crashes qmlscene..****
>>
>> Do i need to do it differently or did i just hit a bug?****
>>
>> ** **
>>
>> Version details:****
>>
>> Qt 5.1.0 x64 (i know, 5.1.1 is out)****
>>
>> Mac Mountain Lion fully updated****
>>
>> ** **
>>
>> Cheers,****
>>
>> Mark****
>>
>
> Hi Jan,
>
> What i try to do is animate the (in this case) width. In a simple
> description that would be it.
> However, i try to animate the with of a component that is within a Layout.
> In this case a RowLayout. If i use the width, the RowLayout itself doesn't
> update, you can see that in this snippet [1]. Just press the nice orange
> square :) What i want for that is to work. I tried animating the
> Layout.preferredWidth property because changing the width using that does
> update the RowLayout, but then the animation doesn't work.
>
> That's all i'm trying to do.
>
> [1] http://pastebin.kde.org/pxgjxhtza
>

Another bump.
I haven't figured out a way to make this animated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20131008/97acaf93/attachment.html>


More information about the Interest mailing list