Re: repeat with messages

2014-05-17 Thread Björnke von Gierke
Just for the record, there's a lot of places where you can append more code or garbage to properly formatted commands without any error, sometimes functional, sometimes not. Basically appendixes of non-functional code. All these examples compile without problem: split x by return and tab put

Re: repeat with messages

2014-05-16 Thread Jerry Jensen
On May 16, 2014, at 8:30 PM, Richard Gaskin wrote: > The compiler's errors are generally limited to those things the engine > requires to be able to tokenize a script. Ignored elements are anomalies, > but apparently won't stop either compilation or execution. > > Feature, perhaps? :) > > >

Re: repeat with messages

2014-05-16 Thread Richard Gaskin
Jerry Jensen wrote: OK Richard, sorry for the TL;DR. Here is what I was trying to present: Mark S. presented a line of code: repeat with x = 100 down to 0 with messages I was surprised to see, in a single line of code: repeat ... WITH MESSAGES which isn't in the dictionary syntax description

Re: repeat with messages

2014-05-16 Thread Jerry Jensen
On May 16, 2014, at 6:33 PM, Richard Gaskin wrote: > There's a lot there, but if I'm following this correctly the answer to your > question of whether you should have been able to anticipate that the wait > could account for this Mac anomaly is no, and thankfully no will need to deal > with it

Re: repeat with messages

2014-05-16 Thread Dar Scott
Well, yeah, normally it is paired, but this is just a trick. If there is really a “paint now” command, I’d use that. The trick doesn’t seem to work any more. I have to use wait and a wait takes a while. The way to minimize that is to avoid waiting each time through the loop but only wait whe

Re: repeat with messages

2014-05-16 Thread Dar Scott
Serial I/O is unfortunately missing messages. Are you thinking of sockets? I almost always use send. When implementing “blocking” when a customer asks for it (as in a sockets-like implementation on iOS), I might use wait with messages or even wait for message, but that requires flags when I d

Re: repeat with messages

2014-05-16 Thread Richard Gaskin
I presume that it would work the same way tacked onto a > repeat statement? > > Would you like me to file a documentation bug report, or am I missing > something? I don't understand. How can "with messages" be used as part of a "repeat" statement? Way back

Re: repeat with messages

2014-05-16 Thread Jerry Jensen
> I don't understand. How can "with messages" be used as part of a "repeat" > statement? Way back at the beginning of this thread, here's the first interchange: Begin forwarded message: > From: Mark Schonewille > Subject: Re: repeat with messag

Re: repeat with messages

2014-05-16 Thread Richard Gaskin
Jerry Jensen wrote: > On May 16, 2014, at 4:32 PM, Richard Gaskin wrote: > >> Dar Scott wrote: >> >> > I don’t see this in the ‘repeat’ entry in the dictionary. >> >> "with messages" is a modifier for the "wait" command - you'll find >> it documented there. > > I use the wait with messages all th

Re: repeat with messages

2014-05-16 Thread Richard Gaskin
Dar Scott wrote: > So what is the right way to make the screen update? At one time we > could use ‘unlock screen’ but that doesn’t seem to work any more. > Or am I remembering wrong? IIRC each "unlock screen" is paired with a "lock screen" so calling both should work, or using "go this card".

Re: repeat with messages

2014-05-16 Thread Jerry Jensen
On May 16, 2014, at 4:32 PM, Richard Gaskin wrote: > Dar Scott wrote: > > > I don’t see this in the ‘repeat’ entry in the dictionary. > > "with messages" is a modifier for the "wait" command - you'll find it > documented there. I use the wait with messages all the time in a project that takes

Re: repeat with messages

2014-05-16 Thread Dar Scott
So what is the right way to make the screen update? At one time we could use ‘unlock screen’ but that doesn’t seem to work any more. Or am I remembering wrong? And about the compiler… I file a lot of bug reports but reporting every time the compiler does not complain about bad syntax seems e

Re: repeat with messages

2014-05-16 Thread Richard Gaskin
Dar Scott wrote: > I don’t see this in the ‘repeat’ entry in the dictionary. "with messages" is a modifier for the "wait" command - you'll find it documented there. > So are these two the same but the first has no time hit? > > repeat … with messages >… > end repeat > > repeat … > wait 0

Re: repeat with messages

2014-05-16 Thread Dar Scott
I don’t know what you mean by “multiple handlers … simultaneously”. Wouldn’t one entire loop be inside a wait of the other? It seems like it would be easier to use send loops at the right level of processing. Dar On May 16, 2014, at 4:04 PM, Mark Schonewille wrote: > Hi Jerry, > > The "w

Re: repeat with messages

2014-05-16 Thread Dar Scott
Unfortunately, a lot of things compile without complaint. On May 16, 2014, at 3:43 PM, Jerry Jensen wrote: > In a nice example from Mark S., I see the line below. I've never seen the > "with messages" part on the end of a repeat statement. I tried it, and it > compiles and runs without complai

Re: repeat with messages

2014-05-16 Thread Dar Scott
I don’t see this in the ‘repeat’ entry in the dictionary. So are these two the same but the first has no time hit? repeat … with messages … end repeat repeat … wait 0 seconds with messages … end repeat I’ll have to try this. The wait makes the loop a lot slower. Dar On May 16, 2014,

Re: repeat with messages

2014-05-16 Thread Mark Schonewille
Hi Jerry, The "with messages" clause makes a repeat loop non-blocking. This allows you to run multiple handlers with repeat statements simultaneously. I add the wait with messages command at the end of the loop to give the engine more time to update the GUI. Particularly in older versions of