Roll for uielement
Submitted by k_kwiatek on November 20, 2007 - 00:20.
How can I rotate (for example 180 degrees) an uielement?
I used "roll" but I see that this not correct function.
How can I change this fragment of code that is based on "Buttons and signals" example?
<uielement id="scriptlet#toolbar-klepsydra" halign="left" hoffset="20" voffset="60" blend="30" type="flat" zorder="2">
<image id="scriptlet#toolbar-klepsydraimage">
<layer class="base" type="bitmap" src="#glass-klepsydra" /></image>
<behavior>
<action event="enter" type="setProperty" target="scriptlet#toolbar-klepsydra" property="blend" value="100" />
<action event="leave" type="setProperty" target="scriptlet#toolbar-klepsydra" property="blend" value="30" />
<action type="setProperty" event="release" target="rollover-ramp" property="active" value="" />
</behavior>
</uielement>
<ramp id="rollover-ramp" value1="0" value2="80" duration="1" pingpong="true">
<behavior>
<action event="change" type="setProperty" target="scriptlet#toolbar-klepsydraimage" property="roll" value='=getProperty("rollover-ramp","value")' />
</behavior>
</ramp> How can I rotate "scriptlet#toolbar-klepsydra" which is uielement?
Karol
fieldOfView | SPi-V dev
Re: Roll for uielement
Use rotation, not roll
Myksa
Re: Rotation
Thanks,
I didn't find this in documentation?
Where can I find more about "rotation"?
I still have problems with this part of XML.
Can you help me to rotate an uielement?
The script is at the top of this page.
Karol
Re: Rotation
Turns out the rotation attribute was missing from the documentation. Thanks for spotting that.
As always, post links, not code...
Re: Roll for uielement
Here is the link.
I would like to rotate this rectangle in the top right corner during event="enter" and stop rotating when event="leave".
Karol
Re: Roll for uielement
I must admit it took me a while to figure this out, even with the link.
'rotation' is a property of the uielement, not the image. You are trying to rotate the image node, which is not possible.
target="scriptlet#toolbar-klepsydra"Re: Roll for uielement
Aldo,
many thanks, I spent hours on this example, but I couldn't find what was wrong.
Now it works.
Thanks again,
Karol