Hi Henry,

Here's one example I've been trying to figure out. I don't know whether 
this is a documentation issue or a coding issue. The docs list many items 
as a 'setter'. Sometimes this means you can use them as a getter too, but 
other times you cannot.

For example, you can get the opacity from a view, but you cannot get the 
motion from an animator. Both are listed as a 'getter' in the documentation.


<canvas debug="true">
   <view id="view1" bgcolor="red" width="200" height="200">
     <simplelayout axis="y" spacing="10"/>
     <animator id="a1" motion="linear" attribute="x" from="50" to="100" 
duration="500" start="true"/>

     <text text="${'opacity is ' + view1.opacity}" resize="true"/>
     <text text="${'motion is ' + a1.motion}" resize="true"/>

   </view>
</canvas>

If you run this example, it will show the motion as 'undefined' rather than 
'linear'. This isn't surprising because the object does not store the 
motion type; it only saves the derived quantities.

My questions are:
   - Should I be able to read back the value of any 'setter'?
   - Should the docs indicate the relevant properties as getter/setter?

Thanks!

Phil



_______________________________________________
Laszlo-dev mailing list
[email protected]
http://www.openlaszlo.org/mailman/listinfo/laszlo-dev

Reply via email to