Is Transcript's English orientation a plus or minus? (wasAndy'scomments and positioning...)
Doug Lerner
doug at webcrossing.com
Sun Feb 8 19:20:11 EST 2004
On 2/9/04 9:07 AM, "Dar Scott" <dsc at swcp.com> wrote:
>
> On Sunday, February 8, 2004, at 04:07 PM, Doug Lerner wrote:
>
>> It would be nice to also support a JavaScript-like:
>>
>> b.a = c
>
> What could be a concrete example?
>
> (field "Potatoes Required").textHeight = 20
>
> Or like this?
>
> field("Potatoes Required).textHeight = 20
>
> Just wondering.
>
> (this stack).textHeight =20
>
I think parentheses around the entire expression is more consistent with
other languages. For example, in JavaScript you would create a new date
object with
new Date()
You might get just the 4-digit year with
now = new Date();
year = now.getFullYear();
or you might just do it in one step like:
year = (new Date()).getFullYear();
Of course with Transcript, the = operator means the same thing that the ==
operator means in other languages. That probably can't be changed anymore or
everything wouldn't be backwards compatible. So some other kind of
assignment operator would be needed like
b.a := c (looks like an arrow pointing to the left)
doug
More information about the use-livecode
mailing list