Créer une animation avec OpenLaszlo
Tout est animable avec OpenLaszlo, que ce soit directement "X" ou "Y", ou en passant par une variable comme dans l'exemple suivant.
<canvas width="435">
<view y="10" x="10"
width="435" height="215"
bgcolor="0xeaeaea">
<view y="${100 + 100*Math.sin(0.01745*this.xpos)}"
x="${xpos}"
width="15" height="15" bgcolor="red">
<attribute name="xpos" value="0" type="number" />
<animator attribute="xpos" from="0" to="410"
duration="6000"
motion="linear" />
</view>
</view>
</canvas>
Ressource en anglais sur le forum OpenLaszlo ici